to understand something or become aware of it, often suddenly
I didn't realize the store was closed.
She suddenly realized her phone was missing.
In this meaning, Spanish usually uses darse cuenta de, not realizar.
Common phrases & grammar
suddenly realize · realize the truth · realize the mistake · realize the importance of
realize + noun/pronoun
realize + that + subject + verb