There are many nuances to 1031s, but here's a summary:
- property must be held for trade, business or investment. Personal use property (2nd homes), principal residences and property held for sale (dealers, flippers) does not normally qualify
- real property is only like-kind to real property; and personal property like-kind to personal property. For animals, the same sex must be involved. I've handled cows to cows, stallions to stallions
Shares in a corporation to real estate would not qualify for 1031 deferral, nor would the sale of a partnership interest. That is not to say that corporations and partnerships cannot do exchanges - they certainly can.
Most exchanges today involve selling to one party and acquiring from a different party - a delayed exchange. "Swaps" are still allowed, but very difficult to find.
Here are other examples of allowed exchanges:
1) Conservation easement exchanged for commercial/rental property;
2) Bare land exchanged for 8-plex or other rental property;
3) Agricultural land for a 50% interest in a commercial office building;
4) Bare land for a ski condo that is placed in a rental pool;
5) Farm equipment for other farm equipment;
6) Crop dusting airplane for a newer airplane.
Personal property has a bit tougher like-kind definition as compared to real property, but all of the above are used quite often. I hope this helps!