NGINX Proxy pass replace PNG file

Jason Prouty jprouty at
Thu Jun 23 17:01:35 UTC 2022

Is it possible to replace an PNG file with a local image
I want to reverse proxy to site and then change the image returned

I have tried the sub_filter setting but nothing changes.

server {

location /{
    proxy_ssl_server_name on;
    sub_filter '<img src="' '<img src="';
    sub_filter_once on;

I just want to replace the image of  the proxied;<>
a new image hosted locally on my nginx

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the nginx mailing list