No, HM's and TM's never (see EDIT 2) appear in the regular episodic anime.
It's understandable that these would be omitted from the anime. Often, these would be used in the games to allow the player to access different areas of the game. Because the game was viewed from top down, a simple rock in your path could cause a serious issue. This is why the games had HM's/TM's like Rock Smash, to get around such obstacles.
However, consider a similiar scenario in the anime. If there was a very large rock in the path of Ash and co., they would not likely need a Pokemon to move or smash it. If they did, the rock would have to be pretty massive to block the way, and there would be other ways around it. The use of TM's and HM's in the anime/manga was not as apparent, and was left out accordingly.
From a post on GameFAQs:
In the anime, every pokemon pretty much automatically knows every move
it can learn. Because, ya know... it would make more sense.
And from a thread on PokeCommunity:
I don't think they'll ever be in the anime, since anime-verse move
learning is generally more... dare I apply this term to the anime...
logical than game-verse. Anime-verse TM/HM moves seem to be taught and
worked on and developed like a skill rather than just implanted.
Like... Pikachu and Iron Tail, Baoppu and Solarbeam... they were both
taught and spent time mastering that particular move. They didn't just
randomly learn it from a rather hazy "level up" method.
So yeah, no. TM and HM moves are taught, not implanted. The discs we
use in game don't really work in anime-verse.
EDIT: As noted by @Dragon, there are Pokemon in the anime that know moves that can be learned through HM's/TM's in the games, such as surf and rock climb, but there is no evidence that these moves were learned specifically from an HM or TM.
EDIT 2: As noted by @Dragon and @Riley, there is a Pokemon movie called Pokemon Origins, that seems to have some version of HM's/TM's, as seen here. Sometimes in the Pokemon movies, different aspects are created or shown differently (as plot devices, if necessary). In Pokemon Origins, HM's are mentioned, but their existence in the rest of the anime is still unknown. There is also a reference to a few different HM's/TM's in the manga and the previously linked source, so it seems that they may exist in the Pokemon universe, or at least they did at some point. Credit to @Dragon for this find