You can do it, but it will be much more expensive to buy the Tiagra-equipped bike and then buy Ultegra parts piece-by-piece.
Bike manufacturers get the parts much more cheaply than you can, and that price difference is reflected in the price of the bike.
Also, consider this: Ultegra is an 11-speed group.
Tiagra is 10-speed.
This means that you will need to upgrade the cassette, rear derailleur, and shifters all at once anyhow.
bicycles.stackexchange.com/users/2152/Adam Rice
There is nothing about the wheel or frame that is incompatible with Ultegra R8000.
You might need an adapter for the bottom bracket but that's about it.
However, as others have said, groupsets are much cheaper when they come on a bike than bought separately, so you will not be saving money by upgrading incrementally.
Additionally you will still have 'Tiagra level' alloy frame, wheels and everything else, which will negate having a better groupset to a large degree.
bicycles.stackexchange.com/users/24228/Argenti Apparatus
The only way to make this viable (economically speaking) is to find the parts you're looking for on discount during things like Black Friday.
It's not impossible as I have done so myself, however you'll still have to install everything by yourself or the savings
will vanish when paying the shop to do it for you.
bicycles.stackexchange.com/users/46150/eethirteenzz
You could perhaps consider (if you go for the upgrade instead of the different bike route) to only replace some (the most important) parts with ultegra(or 105 if you want to save some money) and leaving the rest of the drive train parts as is (spec wise) or replacing them with higher spec but lower than ultegra/105.
In my opinion the rear derailleur/shifter are the most important/first parts to upgrade since you shift a lot more with the rear derailleur and adjustment and such needs to be a lot more precise to produce clean shifts than in the front.
Shifters will last you a very long time and shifting performance is very much related to proper shifters.
Also make sure your shift cables are in good condition to get optimal shifting performance.
Example setup:
Rear derailleur: ultegraFront derailleur: 105/tiagraChain: 105/tiagraShifters: ultegra
In my opinion this is a good compromise in terms of price/performance.
You could change the example by replacing Integra by 105 and 105 by tiagra to get a cheaper but still adequate option.
The modern tiagra parts are quite good imo.
Regarding ultegra being 11 speed and 105 being 10 speed: in my experience derailleurs are not speed specific and Shimano derailleurs with different 'rated' speeds can be used interchangably when using the correct shifter (same number of gears) for the casette/freewheel.
So you could also consider 105 shifters, ultegra RD and 10 speed chain as an option In regards to cutting costs: try finding the parts used but new (bought but never used) on eBay or another second hand marketplace.
Good deals can occasionally be found :)
bicycles.stackexchange.com/users/34221/Maarten -Monica for president
Another point that could trip you up, is that tiagra 10 speed is unique and weird in its cable pull.
This means Tiagra 4300 is not compatible with any other 10 speed groupset parts.
So its an all-or-nothing change for you, have to do the right brifter and rear derailleur together.
bicycles.stackexchange.com/users/19705/Criggie
Can I change group set of this bike from Tiagra to Ultegra 8XXX without changing wheel? If yes, does it depend on geometry of rear fork?  I am asking because I would like to know whether it is cheaper to buy a new bike like this and occasionally change group elements (with used) Ultegra and you will get after some months one pro bike :).  Thanks for your time  More about what I want to buy  here
Buy cheaper bike and upgrade
bicycles.stackexchange.com
<groupsets>
bicycles.stackexchange.com/questions/65153
bicycles.stackexchange.com/users/43962/Emin Hasanov
The general consesus is there is little point upgrading the group set and cheaping a cheaper frame and wheels. Parts are more expensive when bought separately and a large part of the bike is still the lower quality version. Bikes are generally cheaper when bought as a whole item. That being said, there are no real incompatibility between the Tiagra and the Ultegra parts in question. Upgrading a bike piece by piece is more expensive than upgrading the whole bike, and will also leave you with some lower end parts. If you want to do this, try replacing only the most important parts and look for good deals on Ebay and elsewhere. The sheel and frame are compatible with the Ultegra R8000, but the bottom bracket  may need to be adapted.
Upgrading a bike piece by piece is more expensive than upgrading the whole bike, and will also leave you with some lower end parts. If you want to do this, try replacing only the most important parts and look for good deals on Ebay and elsewhere. The sheel and frame are compatible with the Ultegra R8000, but the bottom bracket  may need to be adapted.