Website security basics for small sites

The handful of habits that prevent most website compromises on shared hosting: updates, logins, permissions, HTTPS, backups and fewer moving parts.

Guide2 min readLast updated
On this page
  1. 1. Keep software updated
  2. 2. Protect every login
  3. 3. Reduce what can be attacked
  4. 4. HTTPS everywhere
  5. 5. Correct file permissions
  6. 6. Keep secrets out of the web root
  7. 7. Validate input in your own code
  8. 8. Backups you can restore
  9. 9. Watch for signs
  10. Common questions

Most small sites aren’t targeted personally. They’re found by automated scanners looking for known weaknesses. Remove the weaknesses and the scanners move on.

1. Keep software updated

Out-of-date plugins, themes and applications are the leading cause of compromise. Keeping website software updated

2. Protect every login

Unique passwords, two-factor authentication and limited login attempts. Hosting account security checklist Brute-force login attacks: how to recognise and stop them

3. Reduce what can be attacked

Delete unused plugins, themes, test scripts, old installs and staging copies you’ve finished with. Code that isn’t there can’t be exploited.

4. HTTPS everywhere

How to force HTTPS (redirect HTTP to HTTPS)

5. Correct file permissions

755 folders, 644 files, never 777. File permissions explained (644, 755 and why never 777)

6. Keep secrets out of the web root

No database dumps, backups or config copies in public_html. Storing configuration and secrets outside public_html

7. Validate input in your own code

Prepared statements for SQL, escaping output, checking uploads. Keeping your databases secure

8. Backups you can restore

The safety net for everything else. A simple backup strategy for your website

9. Watch for signs

Unexpected redirects, new admin users, unfamiliar files and warnings from search engines. My website has been hacked: what to do

Prefer to follow along?

New to Traxio? Hosting is £0.99 a month. See what’s included

Common questions

Is shared hosting secure?

Accounts on a shared server are isolated from each other, so another customer’s site cannot read your files. In practice almost every compromise on shared hosting comes from the site itself — an outdated plugin, a weak password or a stolen FTP login — rather than from a neighbour.

This is a general web-hosting explanation, not specific to Traxio.

Which is good news, because those are the things you control. Keeping software updated, using long unique passwords and turning on HTTPS covers the overwhelming majority of real-world attacks.

How do I keep my website secure?

Keep everything updated, use long unique passwords, turn on HTTPS and take backups you control. Those four cover the overwhelming majority of real attacks on small sites — outdated plugins are the single most common way a site gets compromised.

This is a general web-hosting explanation, not specific to Traxio.

Spotted something out of date or unclear? Tell us and we’ll fix it.

Keep going