Yes. There is no federal law or regulation that requires national banks to cash checks for noncustomers. Most banks have policies that allow check cashing services only for customers who have an account with them in order to protect both themselves and their customers from forgeries. Once a national bank cashes a check that has been forged by a noncustomer, they may lose money if they cannot collect from the person who cashed the check. Also, if a national bank agrees to cash a check for a noncustomer, it may legally charge the presenter a fee.
Source: the OCC website
http://www.occ.gov/ there is a link for Are you a bank customer
http://www.helpwithmybank.gov/ from there you can select the cashing checks link.