The regulations and formalities depend on whether you wish to:
Permanent exportation from Switzerland
More information can be found at Permanent exportation from Switzerland.
In the case of used vehicles or cars involved in accidents, you must also take into account the provisions on waste legislation. Information on this can be in found in the following fact sheet or at the Federal Office for the Environment (FOEN):
Using a duty paid vehicle abroad temporarily
Vehicles with Swiss number plates can be taken abroad without customs documents (i.e. informally) and then re-imported.
General information on the temporary use of goods can be found under Temporary exportation.
When returning to Switzerland with the vehicle, you must spontaneously declare all repairs, conversions, enhancements, etc. carried out abroad to the Federal Office for Customs and Border Security at the border. Information can be found at Processing traffic.