Viejo is the masculine word, and vieja is the feminine word for "old" in Spanish. It can be masculine or feminine, according to the gender of the word you are describing.
The expression to say how old you are or a material object is in Spanish is "tener ____ años".If you literally want to translate "years old" into Spanish, this would be "años de vejez", but this is nonsense to any Spanish speaker.
Cuántos años tienes? - How old are you
Viejo or antigua
Viejo/a
ancianos
You say "Ella es vieja"
old house = casa vieja.
'Tengo [number] años.'
hombre viejo.
armada vieja
pedo viejo
i am 41 years old