Skip to content

Instantly share code, notes, and snippets.

@aamishbaloch
Last active November 7, 2024 19:07
Show Gist options
  • Save aamishbaloch/1031e7490d7d57d55baff57fce8d2997 to your computer and use it in GitHub Desktop.
Save aamishbaloch/1031e7490d7d57d55baff57fce8d2997 to your computer and use it in GitHub Desktop.
Remove Server Details from Response Header - Nginx

Remove Server Details from Response Header - Nginx

Below mentioned method is used to hide or remove the NGIX details from the header of your http requests.

Install Nginx Extras

sudo apt-get update
sudo apt-get install nginx-extras

Remove Server Details

Server details can be removed from response by adding following two lines in the nginx.conf (under http section)

more_clear_headers Server;
server_tokens off;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment