This depends on what you mean by “everything.” By default, when you uninstall a package with pacman, all the files owned by that package will be removed from the system. You can check the list of files owned by a package with this command:
pacman -Ql <package>
pacman -Ql firefox
will list out all the files owned by the firefox package.
To remove a package along with its dependencies, run
sudo pacman -Rn <package>
Note, however, that user configuration files (usually the files inside ~/.config directory) associated with that package will not be removed. Cache files (stuff inside ~/.cache) as well as program data files (files inside ~/.local/share and /var/lib) will be left untouched. Basically, pacman will not touch any files associated with the removed package if those files reside in the user’s home directory. So if you want them gone, you are going to have to remove them manually.
You can locate any leftover files from a package with the find command + a glob pattern with the package’s name. For example, let’s say you just uninstalled firefox and you want to find out the leftover files associated with firefox:
sudo find / -wholename "*mozilla*"
sudo find / -wholename "*firefox*"
Caution: Be careful when attempting to delete files (especially system files that are not in your home directory) on your system. Make sure you know what exactly what you’re deleting before proceeding. You have been warned.