Articles on: Magento 2 Pearl Theme User Guide

How to verify the root of my Magento installation using SSH?

When working with Magento 2, you’re often asked by extension providers to connect via SSH to the root of your Magento installation to run installation commands.


If you have multiple Magento installs on your server, it can be confusing to identify the correct one.

Follow these steps to verify that you are in the right place.



Step 1 — Connect via SSH

Connect to your server using an SSH client.

Your hosting provider should supply the SSH credentials.


If you have connection issues, make sure your IP is whitelisted by the hosting provider.



Step 2 — Navigate to your Magento root

Go to the directory where your Magento installation is located. For example:


cd mymagentostore.com/html



Step 3 — Create a test file

Create a simple text file that you’ll later check from the storefront:


nano test.txt


Write some text inside (e.g., verifying my magento installation).


  • Press Ctrl + X to exit
  • Choose Y to save changes


Creating a test file with nano



Step 4 — Verify the file exists

List the files in your current directory:


ls


You should see test.txt in the list.


Verifying the test file exists via ls command



Step 5 — Check from the storefront

Go to your storefront in a browser and access the file directly:


mymagentostore.com/test.txt


You should see the text you added in Step 3.


Accessing the test file from the storefront


If the file displays correctly, you’ve confirmed the root of your Magento installation.



Notes

  • If the file doesn’t show up, repeat Steps 1–5 for another Magento installation path on your server until you find the correct one.
  • If you’re on managed hosting, you can open a ticket with your hosting support and request the installation path directly.

Updated on: 16/09/2025

Was this article helpful?

Share your feedback

Cancel

Thank you!