Although it’s unlikely that you’ll ever hit the maximum Access database size of 2GB, it’s still good to know that you can set your database to automatically compact or shrink the file size. This is especially true for databases where you are adding and removing a lot of data each time.
To enable the automatic compact, open your Access file and go to Tools \ Options.
Select the General Tab and place a checkmark in the box next to “Compact on Close”
That’s it! Now each time the database is opened it will automatically compact the data when you close Access.