It is up to you to check your local state laws to see if there are restrictions to selling firearms online, the rules may vary slightly depending on what state or city you live in, but on a general level they go something like this. If you are the Seller of the firearm(s) you must receive a signed copy of the FFL Dealers licence from the buyer, this license will have the ship to address where you will send the firearm(s). After the transaction is over, make sure that you file away the FFL License as proof of sale.
If you have sold a HAND GUN online and need to ship it to the buyer, you must ship it FROM an FFL Dealer TO an FFL Dealer (Federal Firearms Licenced Dealer) after you get payment of course. Usually an FFL Dealer attach's a small fee additional to the shipping charge. From there it is out of your hands, and up to the buyer to receive it from their local FFL Dealer. It is ALWAYS the customers job to send you a signed copy of the FFL Dealer that the gun must ship to.
Long gun (rifle) transactions are generally easier to handle, it does NOT require that you ship from an FFL Dealer, but it does require that you ship it to an FFL dealer for the buyer to pick it up. It is ALWAYS the customers job to send you a signed copy of the FFL holder that the gun must ship to.
And there is a simple and good reason for these FFL gun transfers, it is the only efficient way to register your firearm, and do background checks.
Sites you can sell your guns on: