> For the complete documentation index, see [llms.txt](https://docs.lightact.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.lightact.com/layers-and-layouts/layer-layouts/variables/global-variables.md).

# Global variables

<div align="left"><img src="https://3312042618-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9sVaJpWJhPbmscipukhh%2Fuploads%2Fgit-blob-4e3700102b1c8cbea933862afe62a6b6d8a6ecf5%2FGlobalVariables1.png?alt=media&amp;token=e04fe515-b1b3-449b-a5e1-996358474c03" alt=""></div>

We can access and manage *Global variables* collapsible from every **Layer Layout** window.

<div align="left"><figure><img src="https://3312042618-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9sVaJpWJhPbmscipukhh%2Fuploads%2Fgit-blob-96fc249375654de8ec9acdd49b70f96edb32d6a9%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure></div>

Alternatively, Global variables can also be accessed from the **Global variables** window.

{% hint style="info" %}
**Good to know**: Global variables are accessible throughout the program which makes them ideal for global show control and data transfer between layers.
{% endhint %}

## Example of using Global variables

Let's say we want to control the opacity of two video layers with just one global variable we create one by pressing the + icon in the **Global variables** section.

<div align="left"><img src="https://3312042618-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9sVaJpWJhPbmscipukhh%2Fuploads%2Fgit-blob-91d76107f467468e811ed33a29dac5973fb05a80%2FGlobalVariables2.png?alt=media&amp;token=07515723-dfa1-4dcb-9a92-1c8060f42af3" alt=""></div>

You can choose from a selection of variables. Let's choose a Float variable for this tutorial.

<div align="left"><img src="https://3312042618-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9sVaJpWJhPbmscipukhh%2Fuploads%2Fgit-blob-d5a8293f856539af60415a102f00dac5a983413d%2FGlobalVariables3.png?alt=media&amp;token=6d6c262c-0668-41b6-9eac-21e1aeeb3155" alt=""></div>

It is a good practice, to give your variables descriptive names, so let's rename it to *Opacity* and change its value.

<div align="left"><img src="https://3312042618-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9sVaJpWJhPbmscipukhh%2Fuploads%2Fgit-blob-284f33024719c3c11d5578cd85cd9034bf3c3b53%2FGlobalVariables4.png?alt=media&amp;token=4ff95118-f009-4ee2-85f8-b0d4d1aea58a" alt=""></div>

Now when we open another video layer we can see that under **Global Variables** there is the *Opacity* float variable we created on another layer with the same values.

<div align="left"><img src="https://3312042618-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9sVaJpWJhPbmscipukhh%2Fuploads%2Fgit-blob-01dd3133c7aabdc0410d8f1cd0348ec34e76eb59%2FGlobalVariables5.png?alt=media&amp;token=d9fd11b5-9023-4e57-b0a2-edfd35a5644e" alt=""></div>
