is it possible to add a custom constraint in PostgreSQL

Now I have a table store some rss subscribe url, sometimes the url end with “https://dba.stackexchange.com/”, now I replace all url without end with “https://dba.stackexchange.com/”. to make sure the sub url did not end with “https://dba.stackexchange.com/”. I want to add a custom constraint in the rss sub source table. If the sub url end with “https://dba.stackexchange.com/”, throw error to the app. I have read the PostgreSQL 13 docs, and found it have many constraint like uniq constraint check constraint with the int data type. but how to add an constraint with a string data type and make sure the string did not end with “https://dba.stackexchange.com/”? is there any way to do this action?