If you make the file shareable via link on Google Drive, you will get a link of following form:
On Overleaf, you can then use the FILE_ID to link a file in your project to that URL. To do this, click on the Upload files button above the file list panel. Select From External URL and enter
where FILE_ID comes from the sharing link above.
Now, if you make a change to the file on Drive, you can pull the new version into your Overleaf project by clicking the refresh link on the linked file.
This works particularly well if you have a Google Drive folder on your computer. Then you can save a file, e.g. an export from a bibliography manager, to your Google Drive and refresh it with one click in Overleaf.
Note that if the file is not set to allow access to anyone with the link, or if you just use the sharing link directly without going through the process above, you may find that the PDF or image file that you upload from Google Drive by URL is not valid. This is because Overleaf will save the Google Drive web viewer page us rather the file itself. If you go through the process above, you should be able to link to the file directly.
You can also use this method to add files from another cloud hosting platform, such as OneDrive, Dropbox, Box.
For Dropbox, replace
dl=0 at the end of the file's URL with
For OneDrive, replace
redir in the file's URL with
See this page for further details on direct links to files on online storage platforms.