If you have a Raspberry Pi and you use it either as a standalone computer, TV entertainment system or video game console, then The possibility of being able to connect it to a computer to manage files and configurations will be very useful for you.
Regardless of how you use your Pi, most operating systems that are available include the option to enable a remote connection to manage the files that your device needs to work with.
In this article, We will explain step by step the most used methods to connect your Pi to your computer with Windows or MacOS and how to get the most out of this quality.
What are the benefits and utilities of connecting your Raspberry Pi to your computer or PC?
The connection between Raspberry Pi and the computer It has a wide range of benefits that vary depending on the operating system installed on the Micro SD of your Pi and the use you are giving it. The most used method of forming a connection, either remotely or via ethernet cable, between a PC and a Rapsberry Pi It is achieved through the activation of the SSH connection protocol that enables connections with external equipment.
This connection method becomes particularly useful when, for example, all you have is the Raspberry Pi motherboard. and you need to perform a remote desktop operation to be able to configure it and perform the necessary actions through a PC.
For users of entertainment operating systems such as OSMC or Batocera, the usefulness of the connection lies in the possibility of direct transfers of multimedia files, in the case of the first, or emulation, in the case of the second, so you always want to maintain a connection with your PC to manage your files.
Learn step by step how to connect your Raspberry Pi to your Windows PC or MacOS computer
The connection methods between Raspberry Pi and a computer vary depending on the objective you have and the settings applied to your Raspberry. One of the most applied methods is the remote connection via local network, for which the configuration of SSH connection it must be enabled on the board.
Next, we will explain in detail the ways in which you can connect your Pi to a computer:
On Windows 10
When enabling a functional connection with a Raspberry Pi, Windows has a certain disadvantage over operating systems such as MacOS or Linux because it does not have an SSH server by default to complete the connection.
Let’s see next:
- Enable SSH on your Raspberry Pi: At this point, you should already have an operating system installed on the Micro SD of your Raspberry Pi. If you don’t have computer peripherals, all you have to do is extract the Micro SD, insert it into your PC, open it and create a file without an extension called “Ssh” . Then insert the card back into your Pi and that enables the SSH connection. If, on the other hand, you have a monitor, keyboard and mouse, all you have to do is open the start menu and enter “Preferences”, open the tab “Interfaces” and enable the option “SSH”.
- Connect the Ethernet cable from your PC to your Raspberry Pi: Make sure the ethernet cable is connected before inserting the power adapter. Once powered on, it will take approximately 30-40 seconds to start the OS and stabilize the connection.
- Check the link on your PC’s Ethernet port: To verify that the connection was made successfully, we will open the Windows command terminal. For this, press “Windows + R” and writes “Cmd” as soon as the terminal opens, type the command “Ipconfig” and find the Ethernet connection. If everything has gone well, it will show us an IP address associated with the Ethernet port. If the final number of the Ethernet IP is “1”, then the IP of the Raspberry Pi will end in “2” or “3”.
- Open the Windows SSH connection tool: When the connection is established, open the PuTTy tool and enter the IP address of your Raspberry Pi. Immediately a command window will pop up requesting some credentials. By default, the username will always be “Pi”. Once you have logged in, the command terminal will open and you can start working remotely.
On macOS
The operating system of computers Apple has the advantage of implementing the OpenSSH free software, which allows it to automatically support the connection with the SSH protocol.
The only requirement is that both the computer and the Raspberry Pi are connected to the same network:
- Install Raspberry Pi OS on your MicroSD: In order to connect your Pi to a PC with MacOS, you must make sure that the MicroSD card of your Raspberry Pi has the Raspberry Pi OS installed, along with the file that enables the SSH protocol.
- For this, download Raspberry Pi Imager for MacOS. Then, open the Raspberry PI Imager and follow the instructions to write the operating system to the Micro SD quickly and easily.
- Get the IP address: All you have to do is obtain the IP address by inserting the following command in your PC’s terminal: “hostname –I”.
- Establish the SSH connection: Later, you should try to establish the SSH connection by inserting the following command in the terminal: “ssh Username @ IP-address”.
Replace the parameters “Username” by “Pi” which is the default username of the Raspberry Pi. You should also replace “IP adress” with the address obtained with the command: “hostname”. As soon as you have logged in for the first time, the system will display a security and authentication notification, make sure you read it correctly and write “And it is” in the terminal, it will finally request the password, which by default will be “Raspberry” and finally you will have all the access to the command terminal of the Raspberry Pi.