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.
On Fedora, Apache HTTP Server is packaged as httpd, not apache2. A working VPS setup has four parts: install httpd, start it and enable it at boot, allow HTTP and HTTPS through Fedora’s firewalld, and verify the server from a browser. HTTPS is a separate task because an open port alone does not provide encryption; Apache also needs mod_ssl and a certificate.
What you need before installing
These steps apply to a Fedora VPS where you can open a shell and run commands with sudo. They configure Apache and Fedora’s local firewalld. If your hosting company provides an additional network firewall or security-group panel, that control is outside the operating system and is not changed by the commands below.
- A running Fedora VPS and an account with
sudoprivileges. - An SSH session or local console connected to the server.
- Network access to Fedora package repositories.
- The server’s public IP address if you will test it from another computer.
Fedora’s package name is an important distinction. Debian- and Ubuntu-based instructions commonly use apache2; using that name with Fedora’s dnf command will not install the Fedora Apache package. Use httpd instead.
Install Apache with dnf
Recommended: install the httpd package
- Connect to the VPS and refresh your package metadata if your normal administration practice requires it.
- Install Apache with:
sudo dnf install httpd
dnf resolves the package and its dependencies, then asks you to confirm the transaction. Review the package list and enter y when prompted. If the package is already installed, dnf reports that there is nothing to do; you can continue to the service step.
#1 Best Overall
Alternative: install Fedora’s Web Server package group
Fedora also documents a group installation:
sudo dnf group install "Web Server"
A group installs a set of related packages rather than only the Apache package. Choose it when you specifically want Fedora’s Web Server collection. For a minimal VPS where you want to control exactly what is installed, sudo dnf install httpd is the clearer choice.
| Method | Command | When it fits |
|---|---|---|
| Single package | sudo dnf install httpd |
Most installations; keeps the initial package set focused on Apache. |
| Package group | sudo dnf group install "Web Server" |
When you want the related packages included in Fedora’s Web Server group. |
Start Apache and enable it after reboots
Installing a package does not by itself guarantee that the web server is running or that it will start after a reboot. Use one command to perform both actions:
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →sudo systemctl enable --now httpd
The --now option starts the service immediately. enable registers it to start during the normal boot process, so a VPS restart does not leave the site offline.
Check the service state with:
sudo systemctl status httpd
Look for an active or running state. The status view can be long; press q to exit. If the service is not running, the status output usually includes the latest failure reason. Copy that message before changing configuration, because it identifies whether the problem is a syntax error, a missing file, a permission issue, or another startup failure.
You can also separate the two operations when troubleshooting:
sudo systemctl start httpd
sudo systemctl enable httpd
The combined command is normally preferable because it prevents the common mistake of starting Apache for the current session but forgetting boot-time enablement.
Rank #2
Allow web traffic through Fedora’s firewalld
Fedora commonly runs firewalld as its host firewall. Apache can be healthy locally while remaining unreachable from the internet if the firewall does not allow the web services. Add both HTTP and HTTPS as permanent services:
sudo firewall-cmd --add-service=http --add-service=https --permanent
sudo firewall-cmd --reload
The http service corresponds to TCP port 80 and https corresponds to TCP port 443. The --permanent option writes the rules to the saved configuration. --reload applies that saved configuration to the running firewall.
Reloading has an operational consequence: runtime-only firewall changes that were not saved with --permanent are discarded. If you have temporary rules in place, record or save them before reloading.
Command-line option handling has differed in some Fedora releases and in reports from administrators. If your release rejects the combined command, inspect the syntax available on that VPS:
Do these 3 things before closing this tab:
1Scan for outdated or missing drivers - takes under a minute2Clear out junk files and repair common Windows errors3Fix the driver behind crashes, sound loss and screen glitchessudo firewall-cmd --help
Then add the two services using the flag order shown by that help output. Do not assume that a command copied from a different Fedora release will accept every option arrangement.
These rules affect Fedora’s local firewall only. A separate firewall offered by a VPS provider, if enabled for the instance, must be checked in that provider’s console as well; otherwise port 80 or 443 can still be blocked before traffic reaches Fedora.
Verify the installation
Test from the VPS itself
Open a browser on the server, if it has one, and visit:
http://localhost
A successful default installation displays Fedora’s Test Page. This test confirms that Apache is listening locally, but it does not prove that a remote network can reach the VPS.
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →Test from another computer
From a workstation or phone on another network, browse to:
http://YOUR_VPS_PUBLIC_IP
Replace the placeholder with the server’s public address. Seeing the Fedora Test Page remotely confirms the basic chain: Apache is running, firewalld permits HTTP, and the VPS is reachable on port 80. If localhost works but the public-IP test fails, investigate firewall or upstream network controls before changing Apache’s files.
Use a hostname later
A domain name is not required for the initial test. Once DNS points a hostname to the VPS, use that hostname for virtual-host configuration and certificate issuance. Keep the IP-address test as a useful way to distinguish DNS problems from web-server problems.
What the default page does—and does not—prove
The Fedora Test Page is a baseline response from the newly installed server. It proves that the default Apache configuration can answer a request; it does not mean your application has been deployed, that a domain is configured, or that HTTPS is active.
Rank #4
For a real site, you will eventually configure Apache’s document root, virtual hosts, application proxying, logs, and permissions. Those are separate configuration tasks. Make one change at a time and keep the default page available until the new configuration has been tested, because it gives you a known-good reference point.
If you choose a document root outside Fedora’s defaults, account for SELinux policy and file contexts. The installation steps here do not establish SELinux rules for custom paths; consult Fedora’s SELinux documentation for the exact context and labeling procedure for your chosen layout.
Enable HTTPS as a separate step
Opening port 443 does not automatically encrypt traffic. Apache needs the SSL module and a certificate whose name matches the hostname visitors use.
Free tools Windows power users keep installed
One-click scans. No signup required.
Components you need
mod_ssl: Apache’s module for handling TLS connections.- A certificate and private key: The certificate must be issued for the domain you intend to serve. An IP-address test alone is not a substitute for a hostname certificate.
- Port 443 access: The firewalld rule above permits HTTPS at the operating-system firewall.
Using an automated certificate client
One documented Fedora approach installs Certbot and the Apache integration package python3-certbot-apache, together with mod_ssl, from EPEL. Package names and repository availability can vary by Fedora release, so confirm the current Fedora-compatible instructions for the exact release running on your VPS before installing them.
After a certificate client has obtained a certificate, review the generated Apache configuration, test the configuration, and reload Apache rather than blindly restarting it. Keep an SSH session open while making TLS changes so a configuration mistake does not lock you out of the server. Certificate renewal also needs to be verified as part of the deployment; an initially valid certificate is not enough if it later expires.
Self-signed certificates
A self-signed certificate can encrypt a private test environment, but browsers will warn that it is not trusted by a public certificate authority. It is therefore unsuitable for a public production site unless you control and distribute the trusted root to every client. For an internet-facing site, use a certificate issued by a recognized certificate authority and configure Apache for the intended hostname.
Best Value
Troubleshoot common failures
| Symptom | Likely boundary | What to check |
|---|---|---|
dnf install httpd cannot find the package |
Repository or package-name issue | Confirm that the command uses httpd, check repository connectivity, and verify the Fedora release’s enabled repositories. |
| Service is inactive after installation | systemd | Run sudo systemctl enable --now httpd, then inspect sudo systemctl status httpd for the failure detail. |
| Localhost works, public IP does not | Firewall or upstream network | Confirm the permanent firewalld services and reload, then check any separate VPS firewall or security-group control. |
| HTTP works, HTTPS fails | TLS configuration | Verify that mod_ssl, a certificate, and an Apache HTTPS virtual host are configured; port 443 alone is insufficient. |
| Changes disappear after a reboot | Service enablement or firewall persistence | Check that httpd was enabled, and that firewall rules were added with --permanent before the reload. |
| Apache will not start after editing configuration | Apache configuration | Read the exact error shown by systemctl status httpd, undo the last change, and validate the edited file before attempting another start. |
Keep troubleshooting layered. First establish that the package is installed, then that systemd has a running service, then that the local request succeeds, and only afterward investigate external reachability or TLS. This order prevents a network symptom from sending you into unrelated Apache configuration files.
Post-install checks for a VPS
Once the Fedora Test Page is reachable, perform these checks before deploying application content:
- Confirm
sudo systemctl status httpdreports a running service. - Confirm boot enablement so the service returns after a restart.
- Confirm both
httpandhttpsare present in the permanent firewalld configuration. - Test from both
http://localhostand the VPS public IP. - Decide whether the server needs only HTTP during initial setup or whether you will complete TLS before exposing a real site.
- Record which configuration files you change and keep a copy of the last known-good version.
Before putting a public application online, harden the server and application configuration. The basic package-and-firewall sequence establishes connectivity; it is not a complete security review. Apply current Fedora updates, restrict administrative access, use least-privilege accounts, and review Apache and application logs regularly.
Complete command checklist
The following is the shortest repeatable sequence for a basic HTTP installation. Run each command in order and stop to investigate an error rather than continuing blindly.
sudo dnf install httpdsudo systemctl enable --now httpdsudo systemctl status httpdsudo firewall-cmd --add-service=http --add-service=https --permanentsudo firewall-cmd --reload- Browse to
http://localhoston the VPS orhttp://YOUR_VPS_PUBLIC_IPfrom another machine.
After these steps, Fedora should serve its default Test Page over HTTP. Add a hostname, site configuration, TLS module, and certificate only when you are ready to move beyond the baseline installation.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Quick Recap
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.

