According to a 2011 article in the Amarillo Globe News, mayonnaise can safely be heated in a microwave or toaster. Mayonnaise can be used in baking and cooking, so it is fine to heat mayonnaise up, especially if it's on a sandwich or included in any type of casserole.
While it is safe to heat mayonnaise in the microwave, it's not advisable to heat it in a takeout container, water bottle, plastic tub or the jar that contains the mayonnaise. The majority of these containers are not microwave safe and could disperse unsafe particles within the food. Only use containers that are labeled microwave safe.