Yes, you can. When you set up the new Mac and connect it to your Time Machine backup either through the network or via cable, you can select restore from Time Machine Backup during setup. If you have already set up your new Mac and want to now restore, use Migration Assistant found in your Applicatons > Utilities folder.
The instructions can be found on Apple Support. See the link below or search support for Migration Assistant.
From Apple Support:
##Migration Assistant and Setup Assistant
Setup Assistant opens the first time you start up a new Mac. It helps you enter your information about your network, and guides you through setting up a user account on your computer. Use it to transfer user accounts, settings, and documents from another computer to your Mac.
If you don't use Setup Assistant to transfer information when you first set up your new Mac, you can do it later using Migration Assistant.
Migration Assistant in OS X Mavericks and Yosemite can transfer information from other computers that have OS X Snow Leopard v10.6.8 or later installed. If you're migrating from a computer with an earlier version of OS X, update your older computer first, or manually copy your data from one computer to another. If you're migrating from a Windows-based PC to a Mac, you can use the Windows Migration Assistant as part of this process.