Recommended Free Tools
iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
Antihost offers Linux VPS plans with full root access, unlimited traffic on a 1 Gbps port and a 14-day free trial.
To make NGINX accept a domain, connect the domain’s DNS records to the server’s public address, then create a matching NGINX server block. The listen directive chooses the address and port, while server_name chooses the hostname for each request. Use a static-file root for a website, proxy_pass for an application on another port, and a separate SSL listener with a certificate that covers every hostname you publish.
What must be in place first
NGINX cannot make a domain resolve by itself. The DNS zone and the web server perform different jobs: DNS tells a browser which address to contact, and NGINX decides what content to return after the connection reaches that address.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
- Control of the domain’s DNS zone through its registrar or DNS host.
- A server with a public IPv4 address, IPv6 address, or both, and network rules that allow the ports you intend to use.
- NGINX installed and running on that server.
- A website directory for static files or an application listening on a local port for reverse proxying.
- A certificate and private key whose names cover the hostnames you will serve if HTTPS is required.
Provider labels differ. One DNS service may call an address record A, another may expose separate fields for the record name and value. Follow the labels used by your registrar or DNS host rather than assuming that every control panel is identical.
Point the domain at the NGINX server
Create address records
Create an A record for the apex name, such as example.com, pointing to the server’s public IPv4 address. If the server has IPv6, create an AAAA record as well. For www.example.com, either create its own A and AAAA records or use a CNAME that targets the apex name, depending on what your DNS host permits.
#1 Best Overall
- Powerful Turbo Fan:CAGIWIRU Electric Air Duster have reached speed up to 130000RPM,Can efficient remove dust and debris.With LED light and Three Adjustable Speed to meet with different cleaning tasks.
- With Attached USB C Fasting Charging cable.Charing 3 hours,Enjoy up to 240 minutes of use on the lowest setting, For third speed can use for 25mins.with four charging options to meet with your needs.
- Wide Application:Upgraded attached 5 different nozzles,making it suitable for a variety of scenes, such as car,pet, pc, keyboards, and other electronic devices. It also serves for office and home clean duster.
- Handy Design & Portable:Cordless air duster electric nozzle is Light weight and small size, design and comfortable to hold and space saving, convenient to carry around. You can put it in your room or inside the car without taking up space.
- Warranty & Support: Our Electric air duster comes with 5 years warranty and 24/7 customer service. During this period, if you have any questions,pls kindly feel free to contact us.
Do not point a record at 127.0.0.1 or another private address for a public website. Those addresses refer to the visitor’s own network or to an internal network and will not reach your server from the public internet.
Allow time for DNS changes
DNS caches honor the time-to-live configured for each record, and recursive resolvers can continue returning an older answer until that cache expires. The exact propagation behavior depends on the DNS provider, resolver, and previous TTL. A successful lookup from one network does not prove that every visitor has received the new value.
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Clear out junk files and repair common Windows errorsFree Scan →Verify the answer before editing NGINX
Use a DNS lookup utility from a machine outside the server’s network when possible:
dig example.com A
dig example.com AAAA
dig www.example.com A
nslookup example.com
The returned address should be the address assigned to the NGINX server. If DNS returns an old address, fix the DNS record or wait for caches to expire; changing NGINX on the new server cannot correct a DNS answer that still points elsewhere.
How NGINX chooses a server block
Every request is evaluated in two stages. First, listen selects the socket (an address and port). Within the selected listener, NGINX compares the request’s Host header with server_name values. The NGINX documentation describes it this way: “Server names are defined using the server_name directive and determine which server block is used for a given request.”
Rank #2
- Screen Cleaner is Your Screen’s New Bestfriend! - EVEO is proud to present a screen cleaner that’s perfectly suited for your TV. Meet your new screen cleaner, computer screen cleaner, laptop cleaner, iPad cleaner, Macbook,tv cleaner or any other electronic device. Our screen cleaner spray and wipe along with the included plush microfiber cloth, easily removes dust, fingerprints & other smudges on the screen’s surface. Clean effectively for a streak-free screen
- Gentle on your Screens - Our screen cleaner spray and wipes is compatible to be used even for the most sensitive LCD, LED, CRT, and OLED screens in proper use. Be at ease knowing that this product is compatible with all the major brands: LG, SONY, Samsung, Sharp, iPad, iPhone, Android screens, Kindle, PC monitors - we’ve got you covered! Can be used as LCD screen cleaner, tv cleaner, smart tv screen cleaner, and more
- Premium Super Soft Plush Microfiber Cloth - Included in this efficient screen cleaning kit. This screen cleaner spray and wipe has our signature plush microfiber cloth specially designed to comply with screens and monitors and leave them streak-free. Has been shown to effectively absorbs stubborn stains, zero streaks, and no fiber shedding. Always use this together with our screen cleaner for the best results
- Easy-to-Use Screen Cleaner Kit + microfiber cleaning cloth - The EVEO Screen Cleaning Kit will easily be your new favorite tool when it comes to taking care of the things you love most, quick and easy solution for a streak-free screen. Simply screw on the sprayer gun on the screen cleaner bottle. Spray the cleaning liquid onto the microfiber cloth, then wipe the screen until desired cleanliness & shine is achieved.
- Quality Screen Care Kit Worth Purchasing - Enjoy a convenient Screen Cleaner anytime, anywhere you need it. Your satisfaction is our top priority. We stand behind the quality of our products and that’s why, you shouldn’t be worrying at all. We manufacture the Best Screen Cleaner. and can be used for laptop cleaning kit, laptop screen cleaner, tv screen cleaner for smart tv. MacBook screen cleaner, monitor cleaner or screen cleaner spray for electronic devices with microfiber cleaning cloth
| Directive or setting | What it controls | Typical mistake |
|---|---|---|
listen |
The local address and port, such as port 80 for HTTP or 443 for HTTPS. | Defining a block on a port that is not reachable or omitting the SSL listener for HTTPS. |
server_name |
The exact hostnames or patterns that select the block. | Leaving out the apex name, the www name, or a spelling variant that users actually request. |
root |
The filesystem directory used to serve static files. | Pointing at the wrong directory or placing the file outside the path NGINX can read. |
location |
Which URI paths use a set of directives. | Putting proxy directives outside a location or using a more specific location unintentionally. |
proxy_pass |
The upstream URL that receives a proxied request. | Using an application port that is not listening or omitting it from the location block. |
If several blocks share an address and port, NGINX uses the request host to choose among them. When no name matches, the request goes to the default server for that listener. This is why a domain can display NGINX’s welcome page even though a custom file exists: the request reached NGINX, but it did not select the intended block.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Serve a static website for the domain
Create the document root
Choose a directory that contains the site’s files. The following example uses /var/www/example; use a different path if your operating system or deployment layout requires one.
sudo mkdir -p /var/www/example
sudo sh -c 'printf "<h1>Example site</h1>n" > /var/www/example/index.html'
Ensure that the NGINX worker process can traverse the parent directories and read the files. The required user and group vary by operating system, so inspect your distribution’s existing NGINX service configuration rather than applying a universal ownership command blindly.
Add the server block
Place a configuration file in the directory used by your installation. On systems that use an sites-available and sites-enabled layout, create a file such as /etc/nginx/sites-available/example and enable it using the layout’s normal symlink or include mechanism.
server {
listen 80;
server_name example.com www.example.com;
location / {
root /var/www/example;
index index.html;
}
}
The two names in server_name are separate hostnames. Include both only if DNS points both names to this server and the site should answer for both. If you want one name to redirect to the other, create a deliberate redirect block instead of silently serving identical content.
Rank #3
- 【Large size】:Measuring 800 x 300 mm/ 31. 5×12 inches, which is wider and taller than others. Large mouse pad can perfectly fit your keyboard and mouse of any size, and there is also ample space for peripherals such as phones, tablets, etc.
- 【LED backlight mouse pad】:Blade Hawks RGB mouse pad provides 7 static modes and 7 dynamic modes will give you the options you are looking for. Power-off memory function remembers the last lighting mode you selected. The super glow fiber Chroma will give you a colorful gaming setup that you want.
- 【Anti-slip rubber base】:Made from Natural rubber, this gaming mousepad will firmly grip your desktop, allowing you to enjoy the ultimate precision in the games you are most passionate about. It also comes with a texture that enhances this ability even further.
- 【Smooth and waterproof surface】: Micro-textured cloth surface, for extremely precise mouse control and a smooth movement. When liquid splashes on the gaming mouse pad, it forms water droplets and slides down. Will not delay your work or gameplay.
- 【Plug and play】: This mouse and keyboard pad is powered by USB, plug and play, no driver required. One button control light modes. Press one time to change the lighting mode, press twice to change the brightness, press and hold about 3 seconds turn ON/OFF.
Validate and reload
- Check syntax and included files with
sudo nginx -t. Do not reload while this check reports an error. - Reload the running service using your operating system’s service manager, for example
sudo systemctl reload nginx. A reload applies the new configuration without unnecessarily dropping existing connections. - Request both hostnames in a browser or with an HTTP client and confirm that the expected index file is returned.
A successful syntax check proves that NGINX can parse the configuration; it does not prove that DNS, firewall rules, file permissions, or the selected server name are correct. Test those layers separately.
Send the domain to an application on another port
For Node.js, Python, Ruby, Go, or another HTTP application, keep the application on its local port and let NGINX provide the public hostname. The application must already be listening on the address and port used by proxy_pass.
server {
listen 80;
server_name example.com www.example.com;
location / {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_pass http://127.0.0.1:3000;
}
}
The official reverse-proxy guide states: “To pass a request to an HTTP proxied server, the proxy_pass directive is specified inside a location.” Keep proxy_pass inside the location block, as shown. The Host header preserves the domain the visitor used, which matters when the upstream application generates links, selects a tenant, or applies host-based routing. X-Real-IP passes the connecting client address in the form shown; make sure your application is configured to trust that header only from your own NGINX proxy.
Check the upstream independently
From the NGINX server, request the application directly:
curl -i http://127.0.0.1:3000/
If this request fails, NGINX will not be able to proxy successfully. Start the application, correct its bind address or port, or adjust local firewall policy. If the direct request works but the public request fails, inspect the NGINX block, DNS, and network access to port 80.
Rank #4
- 【Softer and More Comfortable】Vaydeer wrist rest has unique diamond pattern, which is the combination of softness and aesthetics. The materials of wrist rest are improved into higher quality memory foam and covered with silky smooth lycra. The computer wrist rest makes you as comfortable and cushiony as like rest your wrists on clouds.
- 【Ergonomic Wrist Saver】The wrist rests for keyboard and mouse comes with a 17.32×3.15×0.83 inch keyboard wrist pad and a 5.94×3.15×0.83 inch mouse wrist support. Based on ergonomic design, the unique concave shape is the perfect fit for your wrist joints. The wrist rest pad fits most computer keyboards and laptops, improve hand and wrist posture, release your wrist and arm stress.
- 【Non-Slip Rubber Bottom】Featuring an anti-skid silicone base on the bottom, this wrist keyboard support stays firmly in place on your desk, preventing the padding from sliding around, ensuring stable and consistent wrist support during extended computer sessions.
- 【Better Experience & Pain Relief】Our keyboard arm rest is beneficial to alleviate the soreness caused by direct contact and friction between your arm and a hard desk surface, reducing the risk of wrist fatigue or carpal tunnel. The soft texture of memory foam can evenly distribute the pressure around your wrists and provide good support with just enough give.
- 【Helpful in Multiple Scenarios】Whether you're working, studying, writing, typing, gaming, this keyboard and mouse rest combo is an essential accessory to add comfort and support to your hands and wrists. It’s also a great gift for men, women, family, friend, coworker, gamer, teacher, etc.
Enable HTTPS for the domain
Configure an SSL listener
HTTPS needs a listener on port 443 and a certificate/private-key pair. The certificate must cover the exact hostname requested by the browser. A certificate for example.com does not automatically cover www.example.com unless that name is also included in the certificate’s names.
server {
listen 443 ssl;
server_name example.com www.example.com;
ssl_certificate /etc/ssl/example/fullchain.pem;
ssl_certificate_key /etc/ssl/example/privkey.pem;
location / {
root /var/www/example;
index index.html;
}
}
NGINX’s HTTPS guidance documents the ssl parameter on listen and the certificate and private-key file directives. Keep the private key readable only by the accounts that need it, and use the paths supplied by your certificate-management process.
Decide what HTTP should do
You can serve HTTP and HTTPS from separate blocks. A common policy is to use port 80 only to redirect visitors to the HTTPS URL, while the port 443 block serves the site or proxies the application. If you instead serve content on both ports, make that choice intentional: users may otherwise continue using an unencrypted URL.
When adding a redirect block, keep its server_name values aligned with the names in the certificate and HTTPS block. Test the apex and www names independently because a missing name can fall through to another server block.
Diagnose certificate-name errors
If a browser reports a certificate-name mismatch, first check the hostname in the address bar and then inspect the certificate’s covered names. Next verify that the request is selecting the intended 443 block. When multiple SSL blocks share the listener, an unmatched name can receive the default server certificate even though another certificate is correctly installed.
Best Value
- 【No Drill Mounted】Cable management tray can be assembled in as little as 3 minutes or less-simply. Side clips easily clampe the edge of desk, pass through the holes on the sides, and secure excess cables with baskets. Desk cable management supports inward or outward installation to meet your needs in different scenarios, and provides you with great convenience when collecting and organizing wires.
- 【Rubber Pad Protects Desk】Wire organizer under desk built-in soft rubber pads on the clamp protect your desk from scratches, so you will not damage your furniture or office.
- 【Sturdy and Beautiful】Cord management under desk is made of high-quality carbon steel and holds about 15 lbs. The wire basket has 2 holes on each side of the tray to enable your cables to pass freely. Cable baskets are suitable for desk thickness use from 0.4" to 2.4".
- 【Space Saving & Keep Organized】Desk cable management tray holds all your power cords, outlet strips, USB hubs and computer transformers hidden from your feet, and the data cables will not enter the vacuum cleaner to keep your desk clean and tidy. Desk wire organizer is also suitable for use in the kitchen and outdoors.
- 【Reduce Safety Risks】Cable tray under desk keeps all plugs away from your kids, no more worry about tripping. Using 2 holes wire tray saves extra space, helps you easily cabling and wire protection. The mesh design is not easy to accumulate dust, but avoids safety accidents caused by messy wires.
Prevent the default site from winning
Match every public hostname
List every hostname that should be accepted in the intended block. A block containing only example.com will not match www.example.com. Likewise, a typo, an unexpected trailing name, or a request made directly to the server’s IP can select a different block.
Understand default_server
Use listen 80 default_server; only on the block that should handle unmatched HTTP requests. The same principle applies to the HTTPS listener. A default block can return a deliberate error or redirect, but it should not accidentally expose the welcome site or another customer’s content.
Test the Host header
After DNS is correct, test the intended name explicitly:
curl -i -H 'Host: example.com' http://SERVER_IP/
Replace SERVER_IP with the server address. This test reaches the server while forcing the hostname NGINX evaluates. If it returns the expected site, but a normal browser request does not, investigate DNS, cached redirects, or an intermediate proxy. For HTTPS, use a client that can connect to the server address while sending the desired name, and verify the certificate as well as the response body.
Use wildcard and internationalized domain names correctly
Wildcard hostnames
NGINX supports documented wildcard forms in server_name. A pattern such as *.example.com is intended for names below the apex; keep an explicit example.com entry when the apex itself must work. Do not use a wildcard merely to hide an incorrectly configured hostname: DNS still has to direct each requested name to the server, and HTTPS certificates must cover the names users will visit.
Internationalized domain names
Internationalized domain names are represented in DNS and NGINX configuration using their ASCII-compatible Punycode form. Convert the domain to the correct Punycode label before placing it in server_name, and obtain a certificate containing the corresponding internationalized name. Mixing a displayed Unicode spelling with the wrong ASCII label prevents matching.
Fix a server-name hash startup error
NGINX stores names in a hash for fast matching. A configuration with many names or unusually long labels can trigger a startup message saying that NGINX cannot build the server-name hash. Follow the adjustment suggested by that error: increase server_names_hash_bucket_size or server_names_hash_max_size in the appropriate HTTP-level configuration, then run nginx -t again before reloading.
Increase only the setting identified by the error and keep the change in a central HTTP configuration context rather than inside an individual server block. The exact value is environment-dependent; the error message is the authoritative indication that the current table is too small.
Quick Recap
Choose the configuration pattern that matches your site
| Use case | Listener and names | Request target | Security consideration |
|---|---|---|---|
| One static site | Port 80, exact apex and optional www names |
root directory and an index file |
Add a separate 443 block and certificate when HTTPS is required. |
| Application on port 3000 | Port 80, exact names that DNS directs to the server | proxy_pass http://127.0.0.1:3000 inside location / |
Keep the application port private when only NGINX should be public. |
| Static site over HTTPS | Port 443 with listen 443 ssl |
Filesystem root | Certificate and private key must cover every requested hostname. |
| Many subdomains | Exact names or documented wildcard syntax | Separate locations or blocks as required | DNS and certificate coverage must include the wildcard’s actual names; large name sets may require hash tuning. |
Troubleshoot by symptom
The domain cannot connect
- Check that A and, if used, AAAA records return the server’s current public addresses.
- Confirm that the server is running NGINX and that the intended port is reachable through network firewalls.
- Verify that the DNS name is not still cached with an old address.
NGINX shows its welcome or default page
- Confirm that the request hostname appears in the intended
server_namedirective. - Look for another block on the same address and port marked or acting as the default.
- Run the Host-header test and inspect enabled configuration files for duplicate or misspelled names.
The browser returns 404 for a static file
- Check that the requested file exists below the configured
root. - Confirm the
indexfilename matches the file actually deployed. - Check directory traversal and file-read permissions for the NGINX worker account.
The proxy returns a gateway error
- Request the upstream URL locally from the NGINX server.
- Confirm that the application is listening on
127.0.0.1:3000or changeproxy_passto its real address and port. - Check the application’s own logs for crashes, bind failures, or a route that rejects the forwarded host.
HTTPS presents the wrong certificate
- Check that the request reaches port 443 and that the 443 block contains the requested name.
- Verify that the certificate file includes both the apex and any
wwwor wildcard name users enter. - Inspect other SSL blocks for an unintended default server that catches unmatched names.
NGINX refuses to reload after adding names
- Run
sudo nginx -tand read the first reported error, not only the final failure line. - Correct duplicate directives, missing braces, invalid paths, or certificate-file permissions.
- If the message concerns the server-name hash, adjust the indicated hash-size directive and test again.
Verification checklist
- DNS A and AAAA answers identify the NGINX server, and a
wwwrecord exists if that name is advertised. - The HTTP block listens on port 80 and lists every hostname it should serve.
- Static sites have a readable
rootand an existing index file; proxied sites have a reachable upstream. - Proxy configurations place
proxy_passinsidelocationand forward the original host when the upstream needs it. - The HTTPS block listens on 443 with
ssl, and its certificate and key paths are valid. - The certificate covers each hostname, including the apex,
www, or wildcard names users will request. - Only the intended block is the default for unmatched requests on each listener.
nginx -tsucceeds before every reload, followed by direct tests of HTTP, HTTPS, and each public hostname.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

