How do I select a non-OEM charger for my device? My Nexus 5 D821 (2014)'s original charger started failing to charge the phone since last week. There are 1.8A &amp; 1.2A LG OEM chargers available in ebay.com. Is it okay to use the 1.8A charger? or Should I go for 1.2A charger?
When you are switching to a different charger from What is OEM supplied, things to bear in mind:


Type of battery (not really relevant these days as most batteries are Li-Ion or Li-PO . Both have sane charging characteristics. Your battery is Li-PO). Battery type dictates charging / charger features
Voltage  This is critical and never use higher rated voltage than
what is specified for your device. For instance do not use 9V tablet charger for your mobile rated at 5V (vice versa is safe but charging will be slower )
Current  This does not matter much since the circuitry inside your phone / battery caters for this and draws as much current as required. Quoting from this


  Each device has a regulator or charge controller, known as a Power Management IC, or PMIC. This device protects the battery from charging too fast, or too slow.



Nexus 5 charging specifications listed at Charge your Nexus device  and as confirmed by OP in his comments as same for his device


  The input voltage range between the wall outlet and this travel adapter is AC 100V– 240V, and the travel adapter’s output voltage is DC 5V, 1.2A


The rating of LG chargers are 1.2 A and 1.8 A and  should be 5V (which is the standard USB charger rating

Having said that, it is playing safer by choosing current rating closest too original-which is 1.2A in your case. 

So you can go in for either LG charger as long rated 5V, but given a choice go in for 1.2 A

Edit


See Complete Guide to Using the Correct Charger or Power Adapter (and What Happens If You Don’t) for similar explanation
To make it easier to understand how Voltage and Current affect charger selection and interpret it in layman terms , adding this example from Basic Electricity



  In some neighborhoods you'll see a water tank raised high above the ground on strong legs. The water in this tank has been raised up there to create pressure in the system. A series of pipes carry the water down from the tank, under ground, into your house, and then to each sink, bathtub, and toilet. The water in your pipes is under pressure because the water in the tank is pushing down on it. This pressure is similar to Voltage. Voltage is the pressure pushing on the electrons in a circuit. 
  
  If all of the faucets in your house are closed, no water flows through the pipes. If you open one faucet, some water flows. If you open all of the faucets, a lot of water flows. This flow of water is similar to electrical Current. Current is the flow rate of electrons through the circuit. 


Correlation of this example and charger selection criteria


Voltage:  If the voltage is too high, the pipes in your home (read device hardware) may burst since they just are not designed to handle
Current:   The flow of water (read Current handling hardware)- if it is too low, you will increase by opening the tap outlet to allow more water and vice versa. This doesn't harm the plumbing of the house