A 1031 exchange defers capital gains and depreciation recapture taxes on the sale of investment, trade or business property as long as the exchanger purchases another like kind of property.
In a delayed exchange, the most common type, the owner sells the relinquished property to a buyer, has the sale proceeds held by a Qualified Intermediary, and then purchases another property from a different party. In a simultaneous exchange the investor swaps the property for one owned by another investor.
For example, if an investor sells a property to a buyer and later purchases that property from the buyer with an LLC in which investor is a member, technically we have not had an exchange. It is two separate transactions. An exchange would require either that the investor swap the building with the LLC or that the investor sell to a buyer, go through the exchange process, and buy another property from seller. Either type of exchange would require an analysis of the related party rules.
The rules and procedures for 1031 exchanges are complex. If you have specific questions, consult a 1031 attorney for advice and guidance.