Formula 1 is an international race where the body of the cars are allowed to be in any design that helps them go fast, and hug the road. There are rules on the size of the engine and the types of tires used, along with several other rules that are designed to keep the playing field even. There were even cars for formula 1 in the 60's that had 6 wheels.
Nascar is based on cars from the showroom of the American manufacturers (it was a only a few years ago that Honda and Toyota were allowed in and it's only because they have American assembly plants.) Every Car is based on a current production model. The rules stipulate that the car design is based on a car that has sold x number of models. The Actual car underneath is vastly different from the showroom car including frame, engine, headlamps, etc... There are many more rules that controll the size of the engine, the type of engine (it has to be a pushrod single cam) The type of carburator, the type of axle (solid live rear axle), The type of brakes, and many more. There are also race specific rules called restrictor plate races that limit the power of the cars.