It is possible but there are often surcharges to do so. Once you start a rental, you will be able to review the terms and condition of the rental. Read all rules carefully. For example, here is some language from Enterprise for a UK rental:
For vehicles travelling to the Republic of Ireland, there is an additional charge of 75 GBP per rental. Please call the branch in advance. Vehicles may not travel outside the U.K. and Ireland.
Additionally, keep in mind that some rental companies may NOT have insurance covering cars while they are on a ferry, so if any damage were to happen to the vehicle while on the ferry between the two countries, the renter may be liable for any costs.