Make sure you have an import visa for your car if you plan to travel outside of the border zone. The border zone is defined as extending roughly 20 to 30 kilometers (12 to 19 miles) from the border, depending on the area of entry; parts of Baja and Sonora may be exempt from this rule. The import visa can be obtained at the border, but it's easier to apply for it beforehand at the nearest Mexican consular office or online through Banjército Bank. You must have the car's registration and title to procure a visa.
Make sure you and your traveling companions have valid IDs. To reenter the United States, you will need to present a valid passport, passport card or enhanced driver's license. Even if you don't plan to reenter the U.S., you will still need a passport if you plan to travel outside of the border zone into Mexico's interior. If you are a Green Card holder, be sure to bring that as well. Other documentation may be needed — for example, if you have minors or pets with you — so be sure to check the Mexican Embassy's website for the latest requirements.
If you have not gotten a tourist visa at a Mexican consulate, you will need to get one once you arrive at the border. Usually, after they inspect your car, you can get out and walk to the office. Depending on the border crossing it this office may be very easy to find or very difficult. Research the particular crossing you're using before you go to understand the layout.
The tourist visa in this case is a card, also called an FMM or an FM-T. It's very important that you hold onto this card, as you will be asked to present it to Mexican authorities on your way out of the country. Note, however, that if you plan to stay within the border zone and exit Mexico within 72 hours, you do not need to obtain a tourist visa.
Once you have all your papers in order, travel into Mexico and enjoy your trip. You may encounter military checkpoints along the way, but just stay in your car and do what they ask you to do. It will all be fine.
Depending on the time of year when you are coming back into the U.S., the border crossing will either go very quickly or very slowly. Be prepared for a long wait — up to five hours is possible. Make sure you have enough gas and water and snacks for the duration.
You will travel through Mexico's border station, where you turn in your vehicle import visa and your tourist card, and then on to the U.S. border station. The latter includes a very thorough check of papers and your car. They will throw away pork products and plants that they find. Be patient, declare items that need to be declared and you shouldn't encounter any problems.