Skip to main content

Using the In-Browser Terminal

advanced, terminal, commandline, bash 0 Was this answer helpful?

cPanel includes a built-in terminal emulator that gives you command-line access to your hosting account directly from your web browser. This is a convenient alternative to using a separate SSH client.

Please note: Screens and options may vary slightly depending on your cPanel version and hosting plan.

⚠️ Caution: Incorrect changes here can make your website inaccessible. If you are unsure about any step, please contact our support team before proceeding.

Accessing the Terminal

  1. Log in to your cPanel account.
  2. In the Advanced section, click Terminal.
  3. Accept the terms of use (first time only).
  4. A terminal window opens in your browser.

What You Can Do

The terminal gives you the same access as an SSH connection. You can:

  • Navigate files and directories (cd, ls, pwd).
  • Edit files (nano, vi).
  • Manage databases (mysql, mysqldump).
  • Run scripts (php, python, node, bash).
  • Check disk usage (du, df).
  • View logs (tail, cat, grep).
  • Manage Git repositories.
  • Install application dependencies (composer, npm, pip).
  • Compress and extract files (tar, zip, gzip).

Useful Commands

# Check your current directory
pwd

# List files with details
ls -la

# View disk usage summary
du -sh ~/public_html

# View the last 50 lines of an error log
tail -50 ~/logs/error.log

# Search for a text string in files
grep -r "search term" ~/public_html/

# Check PHP version
php -v

# Run a PHP script
php ~/public_html/script.php

# Check available memory and processes
free -m

Limitations

  • The in-browser terminal is subject to the same access restrictions as SSH — you don't have root access on shared hosting.
  • Sessions may time out after a period of inactivity. Long-running commands may be interrupted.
  • For long-running tasks, use screen or nohup to keep processes running even if the terminal disconnects.
  • The terminal may not be available if your hosting provider has disabled SSH access for your account.

Tips

  • Use the terminal for quick tasks. For extended work, a dedicated SSH client (PuTTY, Terminal, MobaXterm) provides a better experience.
  • You can copy and paste in the terminal using standard keyboard shortcuts (Ctrl+Shift+C / Ctrl+Shift+V on Linux, Cmd+C / Cmd+V on macOS).
  • If a command seems stuck, press Ctrl+C to cancel it.

What Next?

Related Articles

knowledgebasedidyoufindanswer