Websites (also called webpages) are today's standard for online presence and a website on Raspberry Pi has enough resources and computational power to handle, host and serve one. Chances are, you already know why you want to use your Raspberry Pi for this purpose. So let's jump into it right away.
Table of Contents
Configuration
Open the terminal in your Raspberry Pi and type the following code:
sudo apt-get install apache2
When prompted if you are fine with the following installation, type ‘Y' (if your system is set in English) and enter to continue.
Testing the website
The most practical way to test a website is of course with a web browser like you are using to read this post!
Method 1
If you don't know how to check your IP address on your Raspberry Pi, check this blog entry or type ‘ifconfig' on the terminal.
Open a new tab and type the IP address of your Raspberry Pi and click enter. In my case, it's:
192.168.100.32
Method 2
To find your device name of your Raspberry Pi, open the terminal and check the name after the ‘@‘.
Open a new tab and type ‘http://‘ and then the name of your device. In my case, it's “raspberrypi3-juditova“.
http://raspberrypi3-juditova/
Result: a website on your Raspberry Pi
You should see a website with a welcome message from Apache2. Congratulations! Now you have a fully operational website on Raspberry Pi.
What's next?
HTML
Do you know how to code in HTML? This programing language is specific for designing webpages, mainly on the frontend. This isn't as hard as a compiled language. Give a try. Click on the image to continue.
If you already know HTML, then proceed to the file /var/www/html/index.html
to edit it.
WordPress
WordPress is open source software you can use to create a beautiful website, blog, or app. It hides many complex programing in the background so you can focus more on the frontend. You can install plug-ins to control what is going on the background and there are also easy to use.
Check out this tutorial on how to make a WordPress website, directly on your Raspberry Pi. Click on the image to continue.
You have reached this far!
Thank you for reading the blog post. Your comments and suggestions are welcomed. At the bottom of this page, leave a message or just say hi! The whole team of techZorro will appreciate it. Don't forget to share it on social media as well.
techZorro’s Index of Content
Click on the following link to browse likewise content in the blog in techZorro. This index will help you see what you are looking for in a bird’s eye view.
techZorro's Newsletter!
If you enjoyed this blog post, please subscribe to techZorro’s newsletter so you don’t miss any future blog posts!