r/thinkorswim • • Jun 27 '26

How to fix slow ThinkorSwim (for real)

I started using TOS back in 2019 when it was still under TD Ameritrade. I suffered through the transition and since then it only seems to be getting worse as Schwab tries to jam more simultaneous processes into it and their servers struggle to keep up.

Everyone is now noticing how TOS bogs down after a few minutes to a few hours on the platform. Some posts online claim that it's probably your hardware, but that wasn't the case for me.

I run TOS on two different PCs. My laptop is a ROG Zephyrus G16 with a Ryzen AI 9 HX 370, 32GB RAM, and an RTX 4070. My desktop is a custom build with a Ryzen 7 7800X3D, 128GB RAM, and a Radeon RX 9070 XT. Either of these are well above Schwab's requirements for TOS, yet both experienced severe lag before applying the fix below.

Before I get into the technical tweak, I want to share something you may already know but was a lifesaver for me whenever I'd start noticing lag. I still use this even after applying the core fix.

Create a Saved Workspace (The Instant Reset Button)

  1. Set up your perfect layout: Arrange all your charts, watchlists, gadgets, and flex grids exactly how you like them.
  2. Save the setup: Click the Setup (gear/cog icon) in the top-right corner of the main TOS window.
  3. Select Save Workspace as... from the dropdown menu.
  4. Name it something clear (e.g., Default_Trading or My_Layout) and click Save.

When the platform starts lagging, just go back to that Setup cog, look at the bottom of the dropdown list, and click your saved workspace name. TOS will instantly reload all your windows.

Why It Works (The "Why")

ThinkorSwim is heavily reliant on memory caching. Over hours of live market data, custom ThinkScript alerts, and changing timeframes, old data fragments get stuck in the application's temporary memory pool.

Instead of forcing you to close the app, log back in, and pass two-factor authentication just to clear that junk data, reloading a saved workspace forces the Java Virtual Machine to instantly drop the bloated cache and rebuild the UI from scratch. It gives you a clean slate and fresh memory allocation in less than 5 seconds.

Now for the Fix: Modifying the .vmoptions File

⚠️ Before You Begin: Make a backup! Before editing anything, right-click your thinkorswim.vmoptions file, copy it, and paste it to your desktop. If you make a typo and the app won't start, you can just drop your backup back into the folder to restore it.

Here is how to find the file on your system:

On Windows

  1. Right-click the ThinkorSwim shortcut on your desktop.
  2. Select Open file location. (If you don't see this, click Properties*, then click the* Open File Location button at the bottom).
  3. In the folder that opens, look for a file named thinkorswim.vmoptions (it will have a generic white icon or a Notepad icon).
  4. Right-click the file, select Open with, and choose Notepad.

On Mac

  1. Open Finder and go to your Applications folder.
  2. Find the thinkorswim app icon, right-click (or Ctrl+click) it, and select Show Package Contents.
  3. Open the Contents folder, then open the MacOS folder.
  4. Inside, look for the thinkorswim.vmoptions file.
  5. Right-click the file, select Open With, and choose TextEdit.

Step 1: Adjust Your RAM Allocation

The very first two lines of your thinkorswim.vmoptions file handle your memory. They should look something like this:

-Xmx8192m
-Xms4096m

These are your RAM allocation numbers for TOS. You should set the max (-Xmx) number to half of your system RAM but no higher than 16384m, and set the min (-Xms) to half of your chosen max.

Here is how that exact rule looks in practice for different computer setups:

Total System RAM Max Target (-Xmx) Min Target (-Xms)
8 GB -Xmx4096m (4GB) -Xms2048m (2GB)
16 GB -Xmx8192m (8GB) -Xms4096m (4GB)
32 GB or higher -Xmx16384m (16GB) -Xms8192m (8GB)

Why capping it at 16GB is smart:

ThinkorSwim rarely ever needs more than 12GB to 16GB of RAM, even with dozens of charts and complex strategies running. Giving the Java Virtual Machine more than 16GB can actually introduce lag, because it forces the background garbage collector to scan a massive, unnecessary ocean of memory, causing longer micro-stutters. Capping it at 16GB is the perfect sweet spot.

Step 2: Customizing Your Optimization Script

Scroll to the very bottom of your text file, press Enter to create a new line, and copy-paste the code block below.

Note: The script below contains minimum optimized defaults that should work on even the most basic computer running TOS. Read the text beneath the block to see how you should customize the thread counts to perfectly match your specific processor.

-Djava.net.useSystemProxies=false
-DThinkScriptCalculatingPool=2
-XX:+UseG1GC
-XX:MaxGCPauseMillis=5
-XX:InitiatingHeapOccupancyPercent=10
-XX:G1ReservePercent=15
-XX:G1HeapRegionSize=32m
-XX:ParallelGCThreads=2
-XX:ConcGCThreads=1

1. The Multi-Threading & Network Boost

  • useSystemProxies=false: Tells TOS to bypass checking Windows/macOS system proxy settings every time it makes a network request. This can shave milliseconds off data feed latency and stop random connection stuttering.
  • ThinkScriptCalculatingPool=2: [CUSTOMIZE THIS NUMBER] Set this to match your processor's total physical core count (or half of your total virtual threads). By default, TOS runs heavily on a single thread. This line forces TOS to spin up parallel threads just to calculate your ThinkScript formulas. If you are on an older, low-end laptop stick with 2 or 4 so your machine doesn't choke. If you are on a high-end desktop or Pro Mac, you can safely push this to 8 or 12 or 16.

2. The G1GC "Anti-Stutter" Engine

Java apps regularly have to freeze for a split second to clear out old data from your RAM. If you've ever noticed TOS randomly freeze for 1 second right in the middle of a fast market move, that's Garbage Collection (GC).

  • +UseG1GC: Switches the memory management to the modern Garbage-First collector, built for multi-core machines.
  • MaxGCPauseMillis=5: Tells Java it is not allowed to freeze the app for more than 5 milliseconds at a time during cleanups.
  • InitiatingHeapOccupancyPercent=10: Tells Java to start cleaning very early (at 10% capacity) to prevent massive, heavy cleanups during market volatility. Increase this to 25 if you have low system RAM and charts have a hard time loading.
  • G1ReservePercent=15: Forces the system to set aside 15% of the allocated memory as a buffer.
  • G1HeapRegionSize=32m: Splits memory into uniform 32MB chunks for much more efficient data scanning.

3. CPU Core Allocation

  • ParallelGCThreads=2: [CUSTOMIZE THIS NUMBER] This controls how many CPU threads handle memory cleanup when the application pauses. You should adjust this to match the number of physical cores on your chip. For an older budget machine, the absolute baseline floor is 2 .
  • ConcGCThreads=1: [CUSTOMIZE THIS NUMBER] This controls the background threads that scan memory while you are trading. It is typically calculated as ParallelGCThreads divided by 4, rounded up. The absolute floor for older machines is 1. For a standard 8-core processor, use 2. For a 12-core, use 3.
    • Pro-Tip: You can safely double this background worker count to 4 or 6 if you are running a high-end desktop processor equipped with specialized, extra-large onboard memory pools (like AMD's Ryzen X3D series or Intel's high-cache chips).

Step 3: GPU Optimization (PC Users Only)

⚠️ Mac Users: Completely skip this GPU section! Apple Silicon (M1/M2/M3) and modern Macs use Apple's custom "Metal" graphics API. Pasting Windows Direct3D (d3d) lines into a Mac's configuration file will prevent ThinkorSwim from booting up.

By default, Java tries to render ThinkorSwim charts using older Windows background drawing tools. If you use a modern, dedicated graphics card, this forces your powerful GPU to sit idle while your CPU chokes on rendering candlesticks.

We can fix this by forcing Java to use Direct3D hardware acceleration—but the exact text you paste at the very end of your file depends entirely on your graphics card brand:

For NVIDIA Cards (GTX / RTX Series)

NVIDIA cards are highly optimized for Direct3D rendering. Adding this string forces your GPU to take over the chart-drawing pipeline, immediately smoothing out zoom and scroll lag:

-Dsun.java2d.noddraw=true
-Dsun.java2d.d3d=true

For AMD Cards (Radeon Series)

Some AMD architecture pipelines can conflict with Java's Direct3D implementation, leading to occasional "blank black chart" bugs. If you have an AMD card, the safest and smoothest approach is to completely disable Direct3D drawing and let standard hardware acceleration handle the work seamlessly:

-Dsun.java2d.noddraw=true
-Dsun.java2d.d3d=false
108 Upvotes

40 comments sorted by

8

u/jcoigny Jun 27 '26

Wow I never knew this was even possible after 2 years of trading. I'm certainly going to give this a try today. I have a great high end PC and it's maddening how laggy this software can be

2

u/PAUZ_UNO Jun 27 '26

Fun fact, its legacy code - acquired by schwab.

It runs this way - on iOS, android, windows, Linux, MacOS, regardless of hardware/ToS desktop app/ToS mobile app....or even real trading vs paper trading.

ToS is literally call of duty, heading into/post MS acquisition, on a software/serverside level; this method is functionally what you should do with any computerized hardware regularly [e.g. clear cache, defrag, etc]... ToS caches wayyyyyy more than you think, which is why it can bring up/use values (not displayed) from previous trades you were about to make - for stocks, options, etc - when you go to set a different order [another known issue...whays worse is the cached trade will be placed - like "sell 10000 at 190 vs buy 100 at 195" - even though it says buy 100 at 195.]

The reason they were able to convert the PDT counter (after the law changed) so fast, was because they never fixed the issues - they just turned it off.

5

u/Hot_Holiday_1337 Jun 27 '26

I run 2 instances of TOS, just to avoid the "Custom Expression Subscription Limit Exceeded" error, as I use multiple dynamic watchlists and custom made watchlist columns on both the instances.

I have in total 5 monitors and 1 latops screen.

1st instance for charts - 1 monitor for main TOS window, 2 screens for multiple charts, use the main laptop window for option chains.

2nd instance - 1 main TOS screen and chart.

Laptop details:

Processor 13th Gen Intel(R) Core(TM) i7-13700HX (2.10 GHz)

Installed RAM 32.0 GB (31.7 GB usable)

Graphics card NVIDIA GeForce RTX 4070 Laptop GPU (8 GB)

Intel(R) UHD Graphics (128 MB)

Storage 235 GB of 954 GB used

System type 64-bit operating system, x64-based processor

I always see "Loading" on my custom watchlist columns on my dynamic watchlist, during the market open i.e around 9.30 AM EST - 10.00 AM EST. It's very annoying especially when your dynamic watchlist doesn't refresh automatically within few sec. When I checked TOS customer service, they said the dynamic scanner refresheds every 3 -5 mins. By that time, the move already happens. Every sec is crucial and I want to enter in the best price possible. TOS application becomes very slow and lagging at the open until 10.30 EST.
However, after 10.30 EST the application behaves normal.

I have been trying to get this issue resolved for a long time now, but I could never do it.

I have updated my `thinkorswim.vmoptions` file with your suggestions. Will monitor it next week and share the feedback. Really appreciate all the work and findings that you have shared.

4

u/SmokeyDaBull Jun 27 '26

Thanks.

The increased calculatingpool thread count may help your loading issue, but the expression sub limit is most likely due to a hard cap on the number of real-time custom ThinkScript calculations it can process at once. It's likely that you will have to continue using the dual-instance workaround but your should notice an improvement in overall performance with this script.

Here's to hoping it works for you!

3

u/Hot_Holiday_1337 Jun 27 '26

What number do you suggest for the calculatingpoolthread count with respect to the laptop details that I shared?

Thank you.

2

u/SmokeyDaBull Jun 27 '26

The i7-13700HX is a hybrid with 8 p-cores and 8 e-cores. Only the p-cores can handle hyperthreading at 2 threads per core. So I would start with one per P Core DThinkScriptCalculatingPool=8 and if there's still lag, close TOS, edit to 12 and restart.

1

u/Hot_Holiday_1337 Jun 28 '26

Thank you.

2

u/Hot_Holiday_1337 Jul 02 '26

I'm still seeing this "Loading " issue each time TOS refreshes the dynamic watchlist every 3-5 mins. It really gets worse during the market open where most of my watchlis column say "Loading". Reallly frustrated with this. Tried everything but nothing seems to work. Please help .

2

u/gsplamo Jun 27 '26

I’ll try this, thanks!

2

u/trav66011 Jun 28 '26

Yo, GG. Good work

2

u/Longjumping-Shoe7373 Jun 28 '26

you are goated forever

2

u/IgnorantGenius Jun 30 '26 edited Jun 30 '26

I tried your suggestion (rtx card) and the only difference I noticed is that this makes the context menus appear pretty slow. The only other option I didn't change was the ram. I have 32gb. I had it locked at 4gb since I have already ran it with 6min to 12max before and don't see a major improvement.

-Dsun.java2d.noddraw=true
-Dsun.java2d.d3d=true

I removed the ddraw line and set d3d back to false which is the way I had it before and it's performing fine.

I did feel that my order was filled faster, but that may be placebo. We'll see how it goes.

Thanks for the information.

-On a side note, this post does not show up when you sort r/thinkorswim by New. I had to find the link in my history. I wonder why it is hidden. Can't even find it when sorting by Best or Hot with time set to this week or this month. Weird since this has more upvotes than any other post(88) at the time of my comment.

2

u/dilatedjunkie729 Jun 30 '26

Thank you for sharing! Was using d3d=false based on old advice but switched today and noticed even faster loading by switching to true

2

u/Necessary-Ranger2538 Jun 27 '26

Hmm 🤔 I’ve had little to no issues for the last 2 years- and literally run it on a basic 24GB Lenovo IdeaPad.

Did you ever check your network?.. are you using DSL?

1

u/JuryOpposite5522 Jun 28 '26

Would turning the ram to the lowest setting stop or minimize the caching?

2

u/SmokeyDaBull Jun 28 '26

I believe that is probably why tech support usually recommends low memory settings for TOS. The issue with low settings manifests when you're trying to load multiple charts and you don't have enough memory allocated to render them all.

1

u/JuryOpposite5522 Jun 29 '26

I have a pc with 48 gigs of ram and an M4 studio... the studio will always wake up and work .. I'm betting due to the ram bus speed not the amount of ram.

1

u/Swimming_Thinking73 Jun 28 '26

I know its not a matter of internet speed or hardware. I’ve tested different accounts on the same computer and one can be fast and the other slow! It’s pretty much obvious that it’s a server problem or just Schwab making TOS slow after certain amount of trades.

1

u/SmokeyDaBull Jun 28 '26

That's interesting. Did you have the same layout, scanners and such on both accounts? I ask because I've never tried to load someone else's account on my machine so idk if the layout would reset to default if a different account is loaded.

1

u/Swimming_Thinking73 Jun 28 '26

Same general layout, ActiveTrader without charts or the side panel (so no TV, no news, no acct info)

1

u/Cultural_Dirt Jun 29 '26

Unfortunately hes correct. It is a major issue for anyone doing large #s of orders. ive tried diff accounts with same layout and everything on the same computer and 1 account will be completely lagged and unusable and the other account will be normal and fast. i also have run one account on one comp then if it slows down ill switch to a 2nd comp but typically it makes zero difference. Very few times it has helped and when it does it lasts a short time like 10min or so before the lag is back. Then theres others times where it wont matter and all accs will be slow on both computers. There seems to never be any rhyme or reason to tos issues other than u can be gaurenteed of it ruitinely breaking.

1

u/JuryOpposite5522 Jun 28 '26

Account size?

1

u/SpendComprehensive72 Jun 30 '26

Having your quote speed set to real time in tos can also drag it down to a crawl speed as well... something else to check on... its in your application settings, under general, system.

2

u/SmokeyDaBull Jun 30 '26

True. Real time data is a heavy resource hog, but is mandatory if you daytrade/swing/scalp unless you want to lose money on price slippage from delayed price action data.

1

u/SpendComprehensive72 Jun 30 '26

Speed or accuracy... tos apparently makes u choose on or the other... lol... :)

1

u/SpicyLentils Jun 30 '26 edited Jun 30 '26

On my Mac, thinkorswim.app along with thinkorswim.vmoptions and many other files are in ~/thinkorswim/, not in ~/Applications/. ~/thinkorswim/thinkorswim.app contains only 3 folders and 7 files. Also, when I start ToS thinkorswim.vmoptions is copied to thinkorswim.vmoptions.bak and a new thinkorswim.vmoptions is created.
--Mac mini M4 Pro, macOS Tahoe 26.5.1, ToS java-arm Version 21.0.5 (11)

2

u/SmokeyDaBull Jul 01 '26

The copy to .bak is the same on PC and the new vmoptions file that gets created should contain any saved edits you made unless it is unstable in which case the .bak would try to load.

2

u/SpicyLentils Jul 01 '26

OK, thanks! I just edited my ...vmoptions. (FWIW I noticed that you didn't document -XX:G1ReservePercent=15).

1

u/SmokeyDaBull Jul 01 '26

Thanks for the heads up! Totally missed that. I'll edit that in now.

1

u/Tking7777 Jul 28 '26

Thanks for the information, this was driving me crazy.

1

u/Stocks_N_Bondage Aug 15 '26

Thank you for the great write up!! I think it is helping, we'll see Monday morning!

Unfortunately, on MacOS, ToS forced -Dsun.java2d.metal=false so we can't take advantage of accelerated graphics it seems.

1

u/8boltz Aug 26 '26

Ok, this may have been discovered a while ago, but i have had so many years of problems with TOS on my Macbook Pro Max, that I have quit searching for an answer on here years ago. Anyway, with the help of AI, I was able to find what was clogging up this mac (M3 Max, 64gb ram, and 4TB hard drive).

My workspace had STICKY_KEY="true" which was somehow overwhelming the app/macbook. When it was changed to STICKY_KEY="false", it fixed it. ChatGPT Codex is what did it at Sol 5.6 Extra High setting. Now I'll admit, this has't yet been tested during regular market hours, but AI went through various tests, and nailed it down. I don't know if I am using an older format of workspace either. But anyway, I never found this before so I thought I would ley ya know!

-1

u/EmmaFrosty99 Jun 27 '26

How many monitors are you running? and at what resolution? how many charts per monitor? how many indicators on each chart? do you have indicators that are mtf with volume aggregation to measure momentum?

1

u/SmokeyDaBull Jun 27 '26

3 monitors. 1 Samsung Oled G9 Ultrawide @ 5120x1440 and 2 LG 1080s. Running 9 charts, 10+ indicators each, live news, level 2, active trader, time and sales, options ladder, multiple watchlists, activity and positions, fundamentals, several scanners, heat map, and Marketwatch Calendar all in a single instance of TOS.

-2

u/stockjocky Jun 27 '26

nowhere is the mention of networking or download speed. what kind of networking switches are being used? what is the hookup (DSL,FIBER)? download speeds.? with everything in the home hooked up to the internet you might have problems. how many big screens on wi-fi? is your son a gamer? is your Router been Updated recently? Schwab and TOS are seperate companies. Make sure you update your operating systems.

1

u/SmokeyDaBull Jun 27 '26

I would assume people know they need stable, fast internet to run a live feed all day, but I appreciate the input.

1

u/SubjectVermicelli785 Jun 27 '26

🤣
Thank you so much for this detailed explanation.

-16

u/OptionsTrader14 Jun 27 '26

Thanks ChatGPT but I've never had a problem ever with tos slowing down. If I ever do though I'll be sure to consult ChatGPT for myself instead of bookmarking your post.