The Macbook is designed by Apple, Inc. as an entry level consumer laptop. Most Macbooks come in a white polycarbonate shell, and all use Intel's Core or Core 2 line of mobile processors, and run Mac OS X version 10.5 or higher. Macbooks can enter sleep mode in two ways: automatically after sitting idle for a certain amount of time and when the lid is closed. Different methods exist to prevent the computer from entering sleep mode in each case.
Preventing Automatic Sleep
Click on the "System Preferences" icon in the dock on the bottom of the screen.
Video of the Day
Click on "Energy Saver" (lightbulb icon) in the System Preferences window.
Click and hold the slider on the sliding scale labeled "Put the computer to sleep when it is inactive for:" and slide it all the way to the right, to "Never." This sets the sleep preference for your current power source, either battery or power adapter.
Click on the drop-down menu labeled "Settings for" at the top of the window, and select the power source you are currently not using. Then repeat step 3. This will ensure that your Macbook will not go to sleep on its own whatever power source you are using.
Preventing Sleep When Lid Is Closed
Plug your power adapter into your Macbook while it is running.
Connect an external keyboard and mouse to the Macbook via USB or Bluetooth.
Connect the Macbook to an external display.
Close the lid. The Macbook will continue to run, using the external display.
Things You'll Need
USB keyboard and mouse