New HACS Integration: pCloud Backup for Home Assistant

Hey everyone :wave:
I just released my first HACS integration — pCloud Backup for Home Assistant — and it has already been added to the official HACS default repo!

:link: GitHub: ghotso/HAS-pCloud-Backup


:star: What it does

This integration adds pCloud as a storage target for Home Assistant’s built-in backup system.
You can also specify the destination folder in pCloud, default is /HomeAssistant/Backups.

Additionally, it provides sensors for monitoring your remote backups:

  • sensor.pcloud_remote_backup_count
  • sensor.pcloud_last_remote_backup
  • sensor.pcloud_last_sync_status

:rocket: Installation (HACS)

Open your Home Assistant instance and open this repository in HACS.

  • Open HACS → Integrations
  • Search for “pCloud Backup”
  • Install → Restart Home Assistant
  • Add the integration via Settings → Devices & Services

A more detailed setup guide is available in the README on GitHub.


:raised_hands: Feedback welcome

This is my first Home Assistant integration — so feedback, bug reports and ideas are very welcome!
If you like it, a :star: on GitHub would make my day :blush:

Cheers,
ghotso

3 Likes

:bell: Small update for anyone using the integration

Just a quick heads-up:
The current version only works with pCloud accounts without 2FA enabled, because Digest Authentication cannot skip the second factor.

I had assumed my dev account had 2FA enabled during testing — turns out it didn’t :sweat_smile:
And since pCloud currently has OAuth app registration closed, adding full 2FA support isn’t possible yet.

I’ve already contacted pCloud support to request OAuth2 client credentials.
As soon as I receive them, I’ll update the integration to support 2FA properly.

:arrow_right: For now: users with 2FA enabled need to temporarily disable it or use a secondary non-2FA account.

Thanks for your understanding — and also for all the feedback so far, this is my first open-source project! :raised_hands:

1 Like

:closed_lock_with_key: Update: pCloud 2FA is now fully supported!

Good news! pCloud has approved my OAuth2 application, and the integration now supports accounts with 2FA enabled :tada:
This means you no longer need to disable 2FA or use a separate non-2FA account.

The latest release includes the complete OAuth2 login flow.
Simply update the integration and re-add to switch over.

Thanks again for the feedback and support :raised_hands:

1 Like

Logger: homeassistant.components.backup
Source: components/backup/manager.py:585
integration: Backup (documentation, issues)
First occurred: 05:59:12 (1 occurrence)
Last logged: 05:59:12

Unexpected error for pcloud_backup.01KABYCW769EW70GX0CWHHGV2F:
Traceback (most recent call last):
  File "/usr/local/lib/python3.13/site-packages/aiohttp/client_reqrep.py", line 539, in start
    message, payload = await protocol.read()  # type: ignore[union-attr]
                       ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/aiohttp/streams.py", line 680, in read
    await self._waiter
asyncio.exceptions.CancelledError

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/backup/manager.py", line 585, in upload_backup_to_agent
    await self.backup_agents[agent_id].async_upload_backup(
    ...<2 lines>...
    )
  File "/config/custom_components/pcloud_backup/backup.py", line 441, in async_upload_backup
    await self.api.async_upload_file(folder_id, backup_name, backup_data)
  File "/config/custom_components/pcloud_backup/api.py", line 246, in async_upload_file
    async with session.post(url, params=params, data=form_data, headers=headers) as response:
               ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/aiohttp/client.py", line 1510, in __aenter__
    self._resp: _RetType = await self._coro
                           ^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/aiohttp/client.py", line 779, in _request
    resp = await handler(req)
           ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/aiohttp/client.py", line 757, in _connect_and_send_request
    await resp.start(conn)
  File "/usr/local/lib/python3.13/site-packages/aiohttp/client_reqrep.py", line 534, in start
    with self._timer:
         ^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/aiohttp/helpers.py", line 713, in __exit__
    raise asyncio.TimeoutError from exc_val
TimeoutError