Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

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

Set up WordPress Multisite on Nginx in this order: back up the existing site, verify pretty permalinks, enable Multisite, create the network in Tools > Network Setup, copy the generated constants into wp-config.php, and install the matching Nginx server rules. Nginx does not read .htaccess, so WordPress cannot create those rewrite rules for you. Subdirectory networks are simpler because they normally need no additional DNS; subdomain networks require wildcard DNS and a matching Nginx server_name.

What WordPress Multisite with Nginx does

WordPress Multisite lets one WordPress installation manage a network of sites. The sites share the WordPress core and can be administered from a Network Admin dashboard, while each site keeps its own content, settings and users as permitted by the network administrator. Nginx serves the files and forwards PHP requests to PHP-FPM; WordPress routes requests to the correct site.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The setup is different from a single-site installation because the URL structure, database tables, cookies, DNS and web-server rewrites all have to agree. A successful dashboard conversion without matching Nginx rules is not a finished installation: the main site may load while subsites, permalinks, media or administration URLs return 404 errors.

Decide between subdirectories and subdomains

Network Setup offers two URL models when the existing installation meets WordPress’s conditions. Choose before creating the network, because changing the model later requires more than changing one constant or a rewrite block.

#1 Best Overall
Sale
Compressed Air Duster,130000RPM Super Power Cordless Air Duster,Rechargeable Brushless Blower,3 Gear Adjustable Blower with LED Light,Dust Remover for Computer/House/Outdoor/Car
  • 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.
Model Example DNS and Nginx requirements Best fit
Subdirectory example.com/site1 Normally no additional DNS records. The primary host’s server block handles every path. Networks that can use path-based addresses and want the least DNS and certificate work.
Subdomain site1.example.com Wildcard DNS for the parent domain and an Nginx server_name accepting the wildcard. The network cannot use only an IP address or localhost. Separate site identities, brands or teams that need a hostname for each site.

When subdirectories are the practical choice

Subdirectories avoid creating DNS records for every new site. They are usually easier to move between hosts because the network remains under one hostname. Check existing paths carefully: a site, application or directory already using the proposed path can conflict with a newly created subsite.

When subdomains are worth the extra work

Subdomains make site addresses clearer when each site is intended to stand on its own. Before testing a newly created site, the parent domain must resolve wildcard hostnames to the Nginx server, and the server block must accept both the main hostname and its subdomains. WordPress specifically does not support a subdomain network based only on an IP address or localhost.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Do not switch models by editing one line

Changing SUBDOMAIN_INSTALL or a rewrite snippet alone does not convert an established network. Stored site addresses, DNS records, the Nginx server configuration and, where applicable, certificates must be changed together. Plan the final URL model before network creation.

Prepare the existing WordPress installation

Make recoverable backups

Create a database backup and a complete copy of the WordPress files before changing configuration. The official guidance is explicit: unless the installation is fresh and disposable, back up both the database and files. Confirm that the backups can actually be restored or downloaded before proceeding.

Verify pretty permalinks first

On the single-site installation, open a post or page that does not use the default query-string URL. If it fails, fix the existing Nginx front-controller configuration before enabling Multisite. Multisite relies on the same request routing, so converting a site with broken permalinks makes later diagnosis unnecessarily difficult.

Deactivate active plugins

Deactivate the active plugins before network creation. Plugins can add rewrite rules, change login cookies or assume a single site. You can reactivate compatible plugins after the network is working and then decide whether each one should run network-wide or only on selected sites.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
EVEO® Screen Cleaner Spray Kit (Streak-Free) TV Screen Cleaner for Smart TV, Lcd, LEd, Oled | Computer Screen Cleaner Spray and Wipe Microfiber Cloth - TV, Monitor, Laptop, iPad, Car - 6.7oz 1 Pack
  • 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

Choose the WordPress directory now

If WordPress should live in its own directory rather than the current document root, make that decision and complete the move before enabling Multisite. Network-generated paths and the Nginx document root must describe the same location.

Enable Multisite in wp-config.php

Open the installation’s wp-config.php and add the following line above the comment that says to stop editing:

define( 'WP_ALLOW_MULTISITE', true );

Save the file, upload it if you edit locally, and sign in again to the WordPress dashboard. The Tools > Network Setup screen should now be available.

Create the network in the dashboard

  1. Open Tools > Network Setup.
  2. Choose Sub-domains or Sub-directories, based on the URL decision you made earlier. The screen may restrict an option when the existing installation does not meet WordPress’s requirements.
  3. Enter the network title and the network administrator’s email address requested by the screen.
  4. Submit the form to create the network tables and generate installation instructions.
  5. Keep the generated instructions open. They contain constants for wp-config.php and rewrite guidance for the installation.

Do not replace the generated block with a generic example. Values such as the authentication keys, cookie settings and site-specific paths must match the installation that just created the network.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Apply the generated wp-config.php values

Network Setup presents a second block of PHP constants. Copy that block exactly into wp-config.php at the location indicated by the screen, normally below the existing WordPress settings and still before the stop-editing comment. The generated values commonly include the network’s subdomain flag, path, site and network IDs, and cookie-related settings; the exact block varies by installation.

After saving the file, sign out and back in if WordPress requests it. The toolbar should expose My Sites and Network Admin. At this stage the database and PHP configuration may be ready, but Nginx still needs the server rules described below.

Rank #3
BladeHawks RGB Gaming Mouse Pad Extra Large Extended 31.5x12 Inch-Black
  • 【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.

Creating the network with WP-CLI

WP-CLI can create the network tables and constants with wp core install-network. Run it from the WordPress installation and use its --subdomains option when a subdomain network is intended. The command’s required arguments depend on the installed WP-CLI version, so inspect wp help core install-network on the server and retain the generated constants rather than inventing replacements.

Configure Nginx instead of .htaccess

Nginx has no .htaccess-type capability. WordPress therefore cannot modify the server configuration or generate the required rewrite rules automatically. The rules belong in the Nginx server block that serves this WordPress installation. The official examples differ for subdirectory and subdomain networks; the following patterns show the parts that must be present.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Replace the document root, PHP-FPM socket and hostnames with the values used by your server. The socket shown below is an example path, not a universal PHP version or distribution setting.

Shared front-controller and PHP handling

Every request that is not an existing file or directory must reach WordPress’s index.php. PHP requests should be rejected when the script does not exist, then passed to PHP-FPM with the standard FastCGI parameters.

root /var/www/example.com/current;

location / {
    try_files $uri $uri/ /index.php?$args;
}

location ~ .php$ {
    try_files $uri =404;
    include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_pass unix:/run/php/php-fpm.sock;
}

Use the actual PHP-FPM socket or upstream name from the host. A wrong socket produces gateway errors even when the WordPress files and rewrite rules are correct. Keep the try_files $uri =404 guard so Nginx does not send arbitrary missing paths to PHP.

Subdirectory network server block

A subdirectory network keeps the primary hostname and routes site paths through the same front controller. The administrative path needs the trailing-slash redirect, and WordPress paths need to remain available to the front controller rather than being treated as unrelated applications.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Sale
Vaydeer Wrist Rest for Keyboard and Mouse, Computer Ergonomic Wrist Support Pad, Soft Memory Foam Arm Cushion for Desk, Palm Hand Office Laptop Typing
  • 【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.
server {
    listen 80;
    server_name example.com;
    root /var/www/example.com/current;

    location = /wp-admin {
        return 301 /wp-admin/;
    }

    location / {
        try_files $uri $uri/ /index.php?$args;
    }

    location ~ ^/wp-.*.php$ {
        try_files $uri =404;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_pass unix:/run/php/php-fpm.sock;
    }

    location ~ .php$ {
        try_files $uri =404;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_pass unix:/run/php/php-fpm.sock;
    }
}

Some Nginx layouts combine the two PHP locations into one regular-expression block. The important requirements are the WordPress front-controller fallback, the /wp-admin trailing-slash handling, the WordPress PHP rewrite pattern, and the missing-script check. Use the version-appropriate official Nginx pattern for WordPress 3.5 and later when your distribution’s include files differ.

Subdomain network server block

A subdomain network uses the same front-controller and PHP handling, but the server name must accept the parent host and arbitrary first-level subdomains.

server {
    listen 80;
    server_name example.com *.example.com;
    root /var/www/example.com/current;

    location = /wp-admin {
        return 301 /wp-admin/;
    }

    location / {
        try_files $uri $uri/ /index.php?$args;
    }

    location ~ ^/wp-.*.php$ {
        try_files $uri =404;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_pass unix:/run/php/php-fpm.sock;
    }

    location ~ .php$ {
        try_files $uri =404;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_pass unix:/run/php/php-fpm.sock;
    }
}

The wildcard in server_name does not create DNS records. It only tells Nginx which requests this block may answer. DNS and the certificate must be configured separately.

Validate and reload Nginx safely

  1. Save the server block in the host’s enabled-sites configuration.
  2. Run the configuration syntax test supplied by your Nginx installation, commonly nginx -t.
  3. Fix every reported error before reloading.
  4. Reload Nginx using the service manager on the host.
  5. Watch the Nginx error log and PHP-FPM log while testing the network.

Do not restart a production server merely to test a syntax change when a reload is available. A successful syntax test means the configuration parses; it does not prove that DNS, PHP-FPM, permissions or WordPress site addresses are correct.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Configure wildcard DNS and HTTPS

DNS for subdomains

Create a wildcard DNS record for the parent domain that points new subdomains to the Nginx server. Depending on the address family and DNS provider, this may be an A record, an AAAA record, or both. Allow the record to propagate before testing a newly created site; a browser cannot reach a hostname that still resolves elsewhere or does not resolve at all.

The Nginx block must contain the same parent domain and wildcard pattern. If DNS points correctly but Nginx has only server_name example.com, a request for site1.example.com can be handled by a different default server.

Best Value
Sale
Under Desk Cable Management Tray No Drill, Metal Mesh Cable Management Under Desk with Clamp Mount, 2 Hole Cable Tray with Wire Management and Cord Organizer for Home Office Standing Desk
  • 【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.

HTTPS for the network

Provision a certificate whose names cover the hosts the network serves. A subdomain deployment normally needs coverage for the parent hostname and its wildcard subdomains. Configure the certificate and key in the TLS server block, then redirect HTTP to HTTPS only after the HTTPS virtual host and WordPress URLs work.

When different sites use different hostnames, certificate selection relies on TLS Server Name Indication (SNI). Every mapped domain needs DNS pointing to the server and a certificate configuration that includes that domain. A wildcard DNS record alone does not provide encryption.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Test the finished network

Test from a normal browser session and, when possible, a private window so old cookies do not hide problems.

  • Open the main site’s home page and a pretty-permalink post.
  • Create a test site and open its front page using the selected subdirectory or subdomain address.
  • Open the test site’s /wp-admin/ and confirm the trailing slash does not loop.
  • Create a page, change its permalink, and reload it while logged out.
  • Upload an image and verify that the media URL loads.
  • Sign out and back in, then switch between the main site and the test site.
  • For a subdomain network, resolve the wildcard hostname and confirm the request reaches the intended Nginx server.
  • For HTTPS, check both the main host and a subsite for certificate-name errors and mixed HTTP links.

Troubleshoot common failures

Symptom Likely cause What to check
A subsite returns Nginx 404 The request is not reaching WordPress’s front controller. Confirm the active server block has try_files $uri $uri/ /index.php?$args, the correct document root and the intended hostname.
Subdomain does not resolve Wildcard DNS is missing, has not propagated, or points to the wrong address. Query the new hostname, then compare the result with the server’s A or AAAA address.
Subdomain reaches another website Nginx has no matching wildcard server_name or the request is selecting the default server. Check the active virtual-host configuration and reload after correcting the hostname.
PHP files download or show a gateway error The PHP location is missing, the script guard is wrong, or PHP-FPM is unavailable. Check try_files $uri =404, FastCGI parameters, the PHP-FPM socket and service logs.
/wp-admin redirects repeatedly The trailing-slash rule, HTTPS termination or site URL does not agree with the request. Test the canonical HTTPS URL, inspect proxy headers when TLS terminates upstream, and ensure the generated WordPress constants and stored site address use the same scheme and host.
Login works on one site but not another Cookies or network constants do not match the generated configuration. Recheck that the Network Setup constants were copied exactly, clear old cookies, and test again in a private window.
Permalinks work on the main site but not a subsite A single-site rewrite block is still active or the network server block is not the one serving the request. Confirm the multisite front-controller rule and inspect the Nginx access log for the requested path.

Map additional domains after the network works

WordPress has native domain mapping from version 4.5 onward. That means a network administrator can associate a site’s own domain without requiring a separate domain-mapping plugin. Native mapping does not remove the server work: the mapped domain must resolve to the Nginx host, the server configuration must accept it, and HTTPS must have a certificate for that name.

Configure and test the primary network first, then add one mapped domain at a time through the network’s site-management settings. Verify the site’s front page, administration URL, login cookies and media under the mapped hostname. Additional domains on the same IP rely on SNI so Nginx can present the correct certificate.

Operational decisions after installation

Reactivate plugins selectively

Once routing and logins work, reactivate plugins one at a time. A network-activated plugin runs across the network, while a site administrator may be allowed to activate a plugin only for an individual site. Confirm that each plugin supports multisite before enabling it globally.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Keep URL changes coordinated

When moving the network, changing its primary domain or switching between subdirectories and subdomains, update the stored site addresses, DNS, certificates and Nginx configuration as one change. A partial change can create redirects to the old host, failed logins or inaccessible subsites.

Use logs as the boundary between layers

Nginx access and error logs show whether a request reached the expected server block and whether the front controller was selected. PHP-FPM logs show PHP execution and socket failures. WordPress network settings explain which site URL should have been selected. Checking these layers in that order prevents changing database values to solve a DNS or Nginx problem.

Key requirements checklist

  • Database and file backups exist and are recoverable.
  • Pretty permalinks work before conversion.
  • Active plugins were deactivated during network creation.
  • WP_ALLOW_MULTISITE was added above the stop-editing comment.
  • The network was created from Tools > Network Setup using the intended URL model.
  • Every generated constant was copied exactly into wp-config.php.
  • The Nginx server block uses the correct document root and PHP-FPM socket.
  • The front-controller, /wp-admin and WordPress PHP rules are installed because Nginx cannot use .htaccess.
  • Subdomain networks have wildcard DNS and a wildcard Nginx server_name.
  • HTTPS certificates cover the hosts being served, with SNI configured for additional domains.
  • Main site, subsite, permalinks, administration, uploads, logins and mapped domains have all been tested.

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.