Even if your data were password-protected, someone who gained access to your computer “would have access to all your files if they were unencrypted.”

Luckily, both Apple and Windows offer means of automatic encryption that simply need to be turned on. In Apple’s macOS, FileVault can be enabled from the Security and Privacy System Preferences panel. Apple has detailed instructions to enable it here. Microsoft Windows users must be running Windows 7 Ultimate or the Professional version of Windows 8, 8.1, or 10 to use BitLocker. Here’s a guide on how to check, and how to turn it on.

Similarly, keep your data backed up. If something happens to it, or you lose it all, you can recover quickly without hassle. An online backup service, like CrashPlan, a favorite of The Wirecutter, a New York Times Company, backs up your data and encrypts it at the same time. Even an external hard drive gives your files an extra layer of security.

Backups will protect your photos, documents and other data not only from a technical malfunction, but from ransomware and other malicious hacking. Just make sure to test or check your backups periodically.

4. The way you handle your passwords is probably wrong and bad.

You know this by now. Creating strong passwords and never using the same password across sites is one of the simplest things you can do to protect yourself from digital invasion. Not everyone agrees about frequent password changes. Most say you should use really strong passwords and no more than one password per site, THEN use the password managers.

But making up new combinations all the time is irritating and inconvenient, tempting people to reuse them or make them too simple. That is one reason some experts object to frequent password changes. It’s far better to create really strong ones for every login. And new passwords can pose security risks, because it’s hard to remember complex ones, so you are tempted to write them down.

That can lead to a lot of hard-to-remember passwords.

To keep track of them, Mr. Larson recommends password managers, which help store many passwords, with one master password. He said he uses LastPass but knows plenty of people who use 1Password and KeePass, and he doesn’t have a strong reason to recommend one over another.