Does valacyclovir work if shingles?

Yes. Valacyclovir (trade name valtrex) is effective against shingles. The faster treatment is started after onset the better it works. Ditto for Famciclovir (famvir).