If you're integrating locize outside of a browser application, you may checkout alternative caching options.

The Cache-Control max-age defines the amount of time a file should be cached for.

The max-age response directive indicates that the response is to be considered stale after its age is greater than the specified number of seconds.

The max-age is expressed in seconds.

Common max-age values are:

  • Disabled cache: max-age=0

  • Five seconds: max-age=5

  • One minute: max-age=60

  • One hour: max-age=3600

  • One day: max-age=86400

  • One week: max-age=604800

When using max-age to define your cache times one should consider how fast your users should be able to request the updated files.

For example for versions used by the development teams we recommend to disable the cache functionality.

For production versions we recommend a low cache value.

Remember: if you for example have a max-age of 604800 your users could have to wait up to one week before receiving the updated file.

On the default version "latest", caching is not possible.

Our advice

  1. Create a dedicated version for production

  2. Do not enable auto publish for that version and publish manually or via API​ or via CLI

  3. Enable Cache-Control max-age​

Last updated