I use glitch for making HTML website and want to create a custom 404 and 403 page. Is it possible to use .htacess on Glitch?
Let’s take a step back to answer your question.
.htaccess files are configuration files for web servers running Apache. The typical setup for Glitch projects serve their webpages via a Node.js web application framework called Express. For such projects, Express serves the same purpose as Apache.
To answer your question: without putting in a bit of work, .htaccess files are useless on Glitch. Express handles things programmatically compared to Apache, which is more configuration-based. That being said, there are more than a few npm packages for Express configuration. It looks like there’s even one for parsing .htaccess files (but it looks like it might be out of date).
I suggest you find a suitable package for Express configuration—not necessarily one capable of parsing .htaccess files—and work from there. Different technologies sometimes have different usage patterns, especially in the sense of the technologies being more “opinionated” than others. In this case, both Express and Apache are somewhat opinionated when it comes to configuration.