You can discuss the cost of fertilizer in terms of the cost per unit, where a unit refers to weight. You would commonly use a pound as a unit of weight.
Most fertilizers contain the three elements nitrogen, phosphorus and potassium. The ratio between these elements in the product is called the N-P-K rating and is usually expressed as three numbers separated by dashes — 10-6-4, for example. The first number is the nitrogen content.
To find the nitrogen content of a fertilizer, multiply the number in the N position of the N-P-K rating by the total weight of the fertilizer. If the N-P-K rating is 10-6-4, for example, and the weight of the bag of fertilizer is 25 pounds, the fertilizer bag contains 2.5 pounds of nitrogen. The one unit of nitrogen in this case would be 1 pound.
Which unit you use to measure nitrogen content isn't important as long as you are consistent. Pounds are the most common unit, but you could use grams instead if you prefer. A unit of nitrogen fertilizer is just one unit of whichever unit you choose to describe the nitrogen content. Calculating cost per unit of nitrogen gives you a better sense of the value of the product you buy.