Help this noob!

If someone is spectating an AOE game and not playing, will that time count toward their recent activity hours and the total hours on record?

TIA
Does playtime on steam include time spent spectating?