This is difficult to accurately answer as switching successfully would depend on the Sprint phone you own. The phone's technology would ultimately be the determining factor on whether or not you can bring your Sprint phone to AT&T.
Sprint phones are normally not compatible with AT&T's network, though there are a few phones that do not apply to these rules.
In the United States, there are two network technologies that rule the mobile phone industry. Sprint runs off a network technology known as CDMA (Code Division Multiple Access). The other network technology is called GSM (Global Systems for Mobile) and is the technology supported by AT&T.
CDMA and GSM are not compatible with one another.
How it works is fairly simple. If you own a GSM phone, your phone is only compatible with GSM technology. If you own a CDMA phone, your phone is only compatible with CDMA technology. This has been the standard rule in the cell phone industry for many years in the United States, however, some Sprint phones support both GSM and CDMA. Phones that support both GSM and CDMA are generally newer model phones.
Own an unlocked Sprint phone? View compatible carriers here
Own an unlocked AT&T phone? View compatible carriers here