# How to map Nginx http response header?

**URL:** <https://www.ruby-forum.com/t/how-to-map-nginx-http-response-header/259083>\
**Category:** NGINX\
**Created:** [March 30, 2020, 10:56pm UTC](https://www.ruby-forum.com/t/how-to-map-nginx-http-response-header/259083 "2020-03-30T22:56:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rdn](https://www.ruby-forum.com/user_avatar/www.ruby-forum.com/rdn/32/2374_2.png) [@rdn](https://www.ruby-forum.com/u/rdn)\
**Post date:** [March 30, 2020, 10:56pm UTC](https://www.ruby-forum.com/t/how-to-map-nginx-http-response-header/259083/1 "2020-03-30T22:56:51Z")

</div>

I tried several configs but seems to not work, like…

Code:

```auto
map $http_x_litespeed_cache_control $nocacheheader {
    default 0;
    no-cache 1;
    }

```

Code:

```auto
map $upstream_http_x_litespeed_cache_control $nocacheheader {
    default 0;
    no-cache 1;
    }

```

Code:

```auto
map $sent_http_x_litespeed_cache_control $nocacheheader {
    default 0;
    no-cache 1;
    }

```

Page is still cached.  
What is the correct format?

My HTTP response header:

> x-litespeed-cache-control no-cache  
> Thanks!
