Obsidian Android - slow startup performance and misleading startup time breakdown

Obsidian Android - slow startup performance and misleading startup time breakdown

Steps to reproduce

Start Obsidian on Android.

Did you follow the troubleshooting guide? [Y]

Yes.

Expected result

Obsidian starts fast.
Performance measurements are correct with/without community plugins.

Actual result

Obsidian starts slow.
Performance measurements with/without community plugins show values which make little sense.

Environment

SYSTEM INFO:
	Operating system: android 13 (Google Pixel 4a)
	Obsidian version: 1.8.3 (183)
	API version: v1.8.3
	Login status: logged in
	Language: en
	Catalyst license: none
	Live preview: on
	Base theme: dark
	Community theme: Underwater v1.6.42
	Snippets enabled: 1
	Restricted mode: off
	Plugins installed: 18
	Plugins enabled: 5
		1: Text Extractor v0.5.2
		2: Keyshots v2.4.0
		3: Style Settings v1.0.9
		4: Templater v2.9.1
		5: Omnisearch v1.25.2

RECOMMENDATIONS:
	Custom theme and snippets: for cosmetic issues, please first try updating your theme and disabling your snippets. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community theme and snippets.
	Community plugins: for bugs, please first try updating all your plugins to latest. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community plugins.

588 files, 28 folders


Additional information

Please see the following measurements:

With custom plugins

Obsidian start-up time breakdown

Operating system: android 13 (Google Pixel 4a)
Obsidian version: 1.8.3 (183)
API version: v1.8.3

- Total startup time: 3,778ms
- Initialization: 590ms
- Vault (586 files): 373ms                   <------ ❗
- Workspace (7 tabs, 6 deferred): 391ms
- Core plugins: 130ms
- Community plugins (6 active): 2,295ms      <------ ❗
  - Omnisearch (v1.25.2): 329ms
  - Text Extractor (v0.5.2): 281ms
  - Keyshots (v2.4.0): 187ms
  - Templater (v2.9.1): 118ms
  - Style Settings (v1.0.9): 87ms
  - Auto Link Title (v1.5.5): 66ms
Obsidian start-up time breakdown

Operating system: android 13 (Google Pixel 4a)
Obsidian version: 1.8.3 (183)
API version: v1.8.3

- Total startup time: 3,527ms
- Initialization: 459ms
- Vault (587 files): 376ms                   <------ ❗
- Workspace (7 tabs, 6 deferred): 354ms
- Core plugins: 143ms
- Community plugins (6 active): 2,194ms      <------ ❗
  - Omnisearch (v1.25.2): 312ms
  - Text Extractor (v0.5.2): 264ms
  - Keyshots (v2.4.0): 169ms
  - Templater (v2.9.1): 87ms
  - Style Settings (v1.0.9): 85ms
  - Auto Link Title (v1.5.5): 65ms

Without community plugins

Obsidian start-up time breakdown

Operating system: android 13 (Google Pixel 4a)
Obsidian version: 1.8.3 (183)
API version: v1.8.3

- Total startup time: 2,624ms
- Initialization: 541ms
- Vault (587 files): 1,488ms                   <------ ❗
- Workspace (7 tabs, 6 deferred): 434ms
- Core plugins: 162ms
Obsidian start-up time breakdown

Operating system: android 13 (Google Pixel 4a)
Obsidian version: 1.8.3 (183)
API version: v1.8.3

- Total startup time: 2,552ms
- Initialization: 457ms
- Vault (587 files): 1,549ms                   <------ ❗
- Workspace (7 tabs, 6 deferred): 409ms
- Core plugins: 137ms

Multiple questions:

  • why the total time for community plugins don’t add up? The sum would be <1s, but total community time is 2.3s which is more than double
  • why is vault time so much higher when I disable community plugins (>1.5s) compared to when they are enabled (0.4s)? This leads me to believe that the time tracking measurement has a bug

Please make [[Obsidian]] on [[Android]] launch as fast as on my desktop (1.1s).
From one developer to another, I can give any logs and take any measurements you may want to aid with figuring this performance issue out, except for sending you my vault. At best, I could send you my .obsidian\ folder.


I created a new topic even though others exist (this for example). If desired, I can move my topic to the other topic.

Because many things run in parallel, the timers aren’t 100% accurate.

Considering, you have a Pixel 4a, your load time isn’t terrible (but could be better). I don’t think you are afflicted by any specific bug (other mobile users are). Therefore, please post in the Feature Request thread.

Thanks for replying, @WhiteNoise and sorry for responding late. I didn’t check the forums ¯\_(ツ)_/¯.

I consider this post as not solved, and the category should still be Bug reports and not Help.

What should I post in there though? I don’t have a feature request here.

Regarding the wildly different timings in with plugins compared to without plugins. I will respond this from the perspective of a Java/Kotlin backend developer who is used to multithreading in many shapes or sizes. Why many? Because the JVM world has a long history and there are many different libraries and philosophies for how to ‘make many things run at the same time’.

Even if things run in parallel, those parallel executions can be measured individually and summed at the end, and total times for phases can also be presented (as they are now).
Right now, there is a wild difference (5-7x) between those 2 cases. If that measurement is meant to help us, it should be implemented better and with more accuracy, otherwise it is misleading.

Going from 373ms vault to 1500ms vault by ‘closing things which might slowdown obsidian’ (the plugins) looks very strange. Now, if those 1200ms can’t be accounted for because very many little things are happening, then perhaps? it would make sense to add another line in that measurements dialog with - Other: 1200ms which appears in both with plugins and without plugins.

Another point what made me confused (and sad afterwards) is that by looking at the startup breakdown, i expected that if i turn off the community plugins, starting obsidian would take 2 seconds less, from 3-4s downto 1-2s, but that was not the case. My obsidian stats are a lie?????????? Goddamnit. (bold for emphasis of my inner monologue, pls don’t hate me)

From another perspective, how can a plugin author trust those measurements if they can vary this wildly when doing perf optimisation work?

And finally, yes, i would love it if obsidian could start in 1s, just like google keep or telegram or poweramp starts (yes, those apps start in 1s if i cold start them after a phone reboot.) The current obsidian speed makes it so that I almost never use it. When i save links or ideas, i always save them into telegram, then copy them from telegram into obsidian when i get to my laptop.

I agree that it needs to improve. The problem is that it tries to load everything monolithically when the editor could be thrown up to start noting right away, just without other features, even as basic as wikilinks.

I had a problem with GrapheneOS killing obsidian even though excluded from battery optimisation, so the startup time was even worse; typically that I couldn’t bear to use it unless intending to use it sitting down on public transport for an extended amount of time organising notes rather than jotting ideas.

In that scenario I started using the ZettelKasten app to quickly note things instead.

Since then I found that iPhone is much, much faster and the app is always available. I also reinstalled GrapheneOS and found that it’s not getting killed anymore. That said, this may keep me stuck to iPhone.

As a reference for anyone else who find this thread, here are my startup times:
GoS: 3.4s.
iPhone 0.5s
Old Macbook: ~2.5s

Detail:

GrapheneOS fresh install:

Obsidian start-up time breakdown

Operating system: android 15 (Google Pixel 6a)
Obsidian version: 1.8.4 (186)
API version: v1.8.4

  • Total startup time: 3,485ms
  • Initialization: 1,551ms
  • Vault (2,754 files): 1,262ms
  • Workspace (8 tabs, 7 deferred): 347ms
  • Core plugins: 326ms

iPhone12:

Obsidian start-up time breakdown

Operating system: ios 18.3 (Apple iPhone13,2)
Obsidian version: 1.8.4 (186)
API version: v1.8.4

  • Total startup time: 867ms
  • Initialization: 463ms
  • Vault (2,756 files): 254ms
  • Workspace (8 tabs, 7 deferred): 110ms
  • Core plugins: 40ms

Old Macbook with many plugins:

Obsidian start-up time breakdown

Obsidian version: v1.8.4
Installer version: v1.8.4
Operating system: Darwin Kernel Version 22.6.0: Fri Nov 15 17:21:49 PST 2024; root:xnu-8796.141.3.709.7~2/RELEASE_X86_64 22.6.0

  • Total startup time: 2,854ms
  • Initialization: 733ms
  • Vault (2,758 files): 443ms
  • Workspace (18 tabs, 18 deferred): 247ms
  • Core plugins: 117ms
  • Community plugins (24 active): 1,314ms
    • NLP (v0.1.3): 653ms
    • Citations (v0.4.5): 165ms
    • Linter (v1.23.2): 98ms
    • Graph Analysis (v0.15.4): 64ms
    • Better Word Count (v0.10.1): 40ms
    • ICS (v0.9.12): 39ms
    • Enhancing Export (v1.10.4): 29ms
    • Pandoc Plugin (v0.4.1): 19ms
    • Image Toolkit (v1.4.1): 19ms
    • Templater (v2.2.3): 18ms
    • Note Refactor (v1.8.2): 18ms
    • Khoj (v1.8.0): 15ms
    • List Callouts (v1.2.7): 15ms
    • Quick Switcher++ (v4.0.0): 13ms
    • Strange New Worlds (SNW) (v1.2.5): 11ms
    • Core Search Assistant (v0.9.2): 10ms
    • Periodic Notes (v0.0.17): 9ms
    • BRAT (v0.8.4): 9ms
    • Nomnoml Diagram (v1.2.0): 8ms
    • Show Current File Path (v0.5.2): 7ms
    • Calendar (v1.5.10): 6ms
    • Recent Files (v1.3.10): 5ms
    • Vault Changelog (v0.1.0): 3ms
    • txt as md (v0.0.1): 2ms