Just like a car, if you want to keep your Mac running at peak performance, do some preventative maintenance from time to time. For starters, adding some RAM almost always helps speed up a Mac, as does giving your hard drive a tune up using Apple's Disk Utility. On the software side, a clean desktop and a clutter-free Dock also helps boost a Mac's performance.
More RAM almost always means faster performance. Unless you paid for an upgrade, there's a good chance that your Mac doesn't have all the memory it can use. For example, a standard Mac computer sold in 2014 comes with only 8GB of RAM, but most can accommodate up to 16GB or 32GB. To check your RAM, select "About This Mac" from the Apple menu, click "More Info," then the "Memory" tab. This tells you how much RAM is installed, what kind it is and how many memory slots you have available. Find out how much memory your model can use from Apple's support website and compare this to what you have installed. Make sure you get the right kind of memory for your specific model.
Cleaning Up Your Drive
Let OS X check for any problems in your disk permissions or the drive itself by running Disk Utility. Found in the Applications' Utilities folder, Disk Utility can verify and then repair disk permissions or problems with the disk itself that could slow down your processes. Since a full drive can also slow down performance, it's a good idea to move files you don't use very often to an external drive. Some stores charge extra for a Mac-formatted drives, but you can save yourself a few dollars by getting one formatted for Windows. As soon as you plug it in, the Mac will reformat it for you in just a few minutes.
Replacing Your Storage Drive
If your Mac didn't come with a solid state drive, or SSD, you may want to upgrade your hard drive to get even more speed. SSDs have no moving parts, making them much faster than spinning hard drives. Apple's Fusion drives are also an option, which combine an SSD with an spinning drive. Fusion drives aren't quite as expensive as SSDs, so you can get more gigabytes per dollar and still benefit from the SSD's fast caching to boost performance. Unlike Windows PCs, Macs don't have a defrag option, nor do they need them. Further, for SSDs, using a defrag utility can actually shorten its lifespan.
Clearing Your Desktop
Keeping files and shortcuts on your desktop may be convenient, but it's a sure-fire way to bog down your system. Every icon you see on the desktop has to be processed and loaded into memory. As these icons accumulate, they can dramatically slow down your Mac. If you really prefer the desktop rather than the Documents folder, try putting your important files in a single folder on your desktop. Having a lot of icons in your desktop Dock and several Dashboard widgets can also slow down your Mac. Remove items from the Dock that you don't use frequently and delete any widgets from the Dashboard you don't really need.
Identifying Monster Apps
If your Mac noticeably slows sometimes but runs faster at other times, launch the Activity Monitor -- located in the Utilities folder under Applications. Click the "CPU" button and then the "Memory" button to see which apps and processes are taking up the most system resources. There may not be much you can do for a resource hog like Photoshop, but for Web browsers, word processors and most other apps, you can often find an alternative that may be kinder to your Mac.