# Download a file

**URL:** <https://forum.robotframework.org/t/download-a-file/6535>\
**Category:** SeleniumLibrary\
**Created:** [4 December 2023 10:39 UTC](https://forum.robotframework.org/t/download-a-file/6535 "2023-12-04T10:39:28Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![VladislavGn](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/vladislavgn/32/2711_2.png) [@VladislavGn](https://forum.robotframework.org/u/VladislavGn)\
**Post date:** [4 December 2023 10:39 UTC](https://forum.robotframework.org/t/download-a-file/6535/1 "2023-12-04T10:39:28Z")

</div>

Hey guys,  
I’m looking for some advice regarding downloading files from a website and saving them in a defined folder?  
I’m trying to find something in RF but nothing that works. I need to download a file by clicking a button on a website and then save the file in a folder that I’ve created, at the end I need to compare text from files but that I’ve already did using Python.

---

<div class="post-metadata">

**Author:** ![falcon030](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/falcon030/32/3420_2.png) [@falcon030](https://forum.robotframework.org/u/falcon030)\
**Post date:** [4 December 2023 13:15 UTC](https://forum.robotframework.org/t/download-a-file/6535/2 "2023-12-04T13:15:37Z")

</div>

@VladislavGn You can do this with Browser Library [https://marketsquare.github.io/robotframework-browser/Browser.html#Download](https://marketsquare.github.io/robotframework-browser/Browser.html#Download). Can you explain what the exact problem is?

---

<div class="post-metadata">

**Author:** ![damies13](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/damies13/32/623_2.png) [@damies13](https://forum.robotframework.org/u/damies13)\
**Post date:** [4 December 2023 15:42 UTC](https://forum.robotframework.org/t/download-a-file/6535/3 "2023-12-04T15:42:27Z")

</div>

Hi @VladislavGn,

Do you need to login and navigate a site first, or is it a simple download this file?

If you need to navigate use Lukas’ suggestion

if it’s a more simple download, [RequestsLibrary](https://marketsquare.github.io/robotframework-requests/doc/RequestsLibrary.html) might be a better option.

There are options, depends what you need to do as to which might be best.

Dave.

---

<div class="post-metadata">

**Author:** ![VladislavGn](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/vladislavgn/32/2711_2.png) [@VladislavGn](https://forum.robotframework.org/u/VladislavGn)\
**Post date:** [4 December 2023 15:53 UTC](https://forum.robotframework.org/t/download-a-file/6535/4 "2023-12-04T15:53:06Z")

</div>

I’m using SeleniumLibrary.  
I’ve solved my problem by changing the default Download directory and adding a custom python function that will compare 2 files.  
Additionally, I’ve added a verification of the number of files in the Downloads folder

---

<div class="post-metadata">

**Author:** ![VladislavGn](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/vladislavgn/32/2711_2.png) [@VladislavGn](https://forum.robotframework.org/u/VladislavGn)\
**Post date:** [4 December 2023 15:53 UTC](https://forum.robotframework.org/t/download-a-file/6535/5 "2023-12-04T15:53:44Z")

</div>

Thx for message, I’ve solved the problem, previous comment is about that

---

<div class="post-metadata">

**Author:** ![Katie](https://avatars.discourse-cdn.com/v4/letter/k/a4c791/32.png) [@Katie](https://forum.robotframework.org/u/Katie)\
**Post date:** [1 November 2024 12:02 UTC](https://forum.robotframework.org/t/download-a-file/6535/6 "2024-11-01T12:02:26Z")

</div>

HI Vladislav, how were you able to change the default Download directory? I’m having issues with downloading to specific directory…
