How to remove rigid body setting from all the objects? I have a big scene that I partly created using rigid body physics. I am happy with the objects now and I applied the visual transform, but I don't know a way to remove all the physics from this system now. 

Joining the meshes sounds kind of a wrong "hacky" way to do it. In some situations joining meshes would be quite bad idea, because it would destroy your parentings and all that plausible other stuff that could be messed up with that method. 

I can also make all the meshes passive simultaneously by holding ALT while doing it, but it doesn't remove the rigid body setting completely. If I try that same ALT clicking for the "rigid body" button, it doesn't do it for all the selected objects, only from the active. 

So what is the correct way to remove rigid body physics from all the objects after you have applied the visual transform from them?
Select rigid body objects run remove operator.

An object is a rigid body if it has a rigid_body property that is not None

is_rigid_body = ob.rigid_body is not None


See Select Active Rigid Body Parts

Script that selects objects if they are a rigid body of a certain type.  Once selected running

bpy.ops.rigidbody.objects_remove()


Will remove the rigid body settings of selected rigid bodies.

Disable the rigid body world

As commented can disable rigid body world.  Cam temporarily disable via

scene.rigidbody_world.enabled = False