Skip to content
ONDI

← All terms

Settings

php -v

A command that shows the PHP version on a server. However, it may differ from the PHP that actually runs your website, so do not rely on it alone.

php -v is a command you type into a server's command screen to see the PHP version number. It is quick, so people use it a lot, but it is common for one server to have several copies of PHP installed. The PHP used on the command screen and the PHP that actually runs your website can be separate. It is like a building with several meters, where you read whichever one is nearest and assume it shows your own shop's usage.

Watch out To see the version your website really uses, check the PHP settings in your hosting control panel, or a temporary check page set up for the purpose. A check page shows server details openly, so delete it as soon as you have looked. Also, some providers apply a fix without changing the number, so an old-looking number may already be fixed. Checking your provider's notice alongside the number is the safe way to be sure.

Source: PHP Manual, “Command line options” · KISA, “Security response guidelines for businesses on the PHP vulnerability (PHP2Shell)” (checked 2026-10-26)

See also

A typo here, a clumsy button there.

This site is still being polished. Spot something? Tell us — we’ll fix it and send a small thank-you gift.

🎁 Thank-you gift