There is no standard answer that always fits every application. Opening and closing a database takes a relatively long time. If the app sends almost continuous updates and queries to the database, there will come a time when opening and closing the database will affect the performance negatively.
Then there is the problem that backing up an open database is a challenge in itself. For performance reasons, the OS can decide not to write the data directly, but to put it in a buffer first. If a problem arises somewhere, the contents of such a buffer may not be written, causing data corruption or loss. For a read-only database is this no issue.
It simply applies that every choice has its own risks and you have to make the right decision for a certain situation.