In Spanish, all nouns always have a gender, which can be masculine or femenine (there are no neuter nouns). It is very important to know if a noun is masculine or femenine, as all the elements that refer to it (articles, adjectives, demonstratives) have to take the same gender:
Este es el edificio más alto de esta ciudad This is the tallest building in this city
Nouns that refer to things (physical objects, ideas, feelings, etc.) have only one gender: some are always masculine and others are always feminine. Generally, the masculine ends in -O, and the femenine endsin -A:
MASCULINE IN -O: el bolígrafo, el dinero, el edificio, el florero, el pañuelo, el vaso
FEMENINE IN A: la cara, la casa, la mesa, la palabra, la plaza, la taza, la ventana