What happens if Bitcoins are sent to a wrong, randomly generated address? I am new to Bitcoin and I confused creating a New Address for receiving and sending payments.

Here's what I did:


Generated a random Bitcoin Address (using www.bitaddress.org)
Created a New Address in my wallet (added it to "Addresses", for SENDING payments - I simply thought this would be my address for receiving BTC)
Purchased BTC in an online exchange and send the money to that address.


What happens to the coins now? Are they lost forever or waiting for someone lucky to get this address to receive payments (if it doesn't exist yet)...? What can I do to get them back, if anything?
Also, is there any way to assign a randomly generated address to my addresses for receiving payments?

Please help.
Well, you don't need different addresses for sending and receiving bitcoins. In fact, you don't have to worry about addresses at all. The Bitcoin client will create addresses when you need one for receiving payments and it will automatically send bitcoins using one of the addresses you previously received coins with.

If you generated the address on bitaddress.org without saving the private key, your coins are lost. The situation may occur that sometime in the future someone will create a new key that's the same as yours and be able to spend your lost coins, but that's extremely unlikely.

If you did save the private keys and you are using the original Bitcoin client (bitcoind or Bitcoin-Qt), you can import the private key as follows:


Close the client that is running. Either close the Bitcoin-Qt client or typing bitcoind stop.
Start bitcoind as a daemon using the command bitcoind -daemon. (If it gives the error that you need to add RPC user details to your bitcoin.conf file, do so, but also add rpcallowip=127.0.0.1 for security.)
If you wallet is secured with a passphrase, unlock it with &lt;space&gt;bitcoind walletpassphrase &lt;your passphrase&gt; 120 The space is for not saving your passphrase into the command history.
Import the private key: &lt;space&gt;bitcoind importprivkey "&lt;your private key&gt;" "&lt;label for key&gt;". (Again the space is for security.)
The private key is now imported in your wallet. You can now lock it again and close the daemon: bitcoind walletlock and bitcoind stop.
You can now reopen Bitcoin-Qt to see the address added.


Then, this answer tells you how to easily add new addresses for receiving bitcoins.