Skip to content
GuidesChecked 20 November 2026

SwiftUI vs UIKit and 22 Apple frameworks, counted

24 Apple frameworks counted in public Swift files on 1 November 2026. SwiftUI leads at 3,190,784 files.

Free for one project and 100 votes. Paid plans start with a 14 day trial, no card.

UI frameworks

SwiftUI is ahead, and AppKit is under a fifth of UIKit.

UIKit has 5.4 times the files of AppKit.

Files that import each UI module
ModuleFiles
SwiftUI3,190,784
UIKit2,879,488
AppKit530,432
WebKit76,416
WidgetKit49,920
Charts31,680
AppIntents24,576
ActivityKit16,256
TipKit4,368

Data and state

The newer data framework leads Core Data, 1.4 to 1.

Files that import each data module
ModuleFiles
Foundation5,808,128
Combine338,944
SwiftData244,736
CoreData172,032
Observation100,864
UserNotifications67,456
CloudKit15,104

Other frameworks

AVFoundation is far ahead of the other frameworks.

Files that import each framework
ModuleFiles
AVFoundation189,184
MapKit74,368
Vision34,176
HealthKit24,992
StoreKit24,544
ARKit20,576
CoreML19,520
FoundationModels12,320

Foundation

Foundation is in 5,808,128 files, 1.8 times the files of SwiftUI.

SwiftUI is in 54.9 of every 100 Foundation files.

UIKit is in 49.6 of every 100 files that import Foundation.

Files per 100 Foundation files
ModulePer 100 Foundation files
SwiftUI54.9
UIKit49.6
AppKit9.1
Combine5.8
SwiftData4.2
AVFoundation3.3
CoreData3.0
Observation1.7

New against old

SwiftUI leads UIKit at 1.1 and SwiftData leads Core Data at 1.4. Observation trails Combine at 0.3.

SwiftUI and SwiftData lead their older pairs.

WidgetKit is in 3.1 times the files of ActivityKit, and AppKit is at 0.2 of UIKit.

Files of the first per the second
PairRatio
SwiftUI per UIKit1.1
SwiftData per Core Data1.4
WidgetKit per ActivityKit3.1
Observation per Combine0.3
AppKit per UIKit0.2

SwiftUI add ons

Five add on frameworks are in far fewer files than SwiftUI: WidgetKit, Charts, AppIntents, ActivityKit and TipKit.

WidgetKit is in 15.6 files for every 1,000 SwiftUI files.

Each figure is the files of the add on per 1,000 files that import SwiftUI. It compares two counts and does not say the same files import both.

Add on files per 1,000 SwiftUI files
Add onPer 1,000 SwiftUI files
WidgetKit15.6
Charts9.9
AppIntents7.7
ActivityKit5.1
TipKit1.4

Machine learning

Vision is in 1.8 times the files of CoreML.

FoundationModels is in 0.6 of the files of CoreML.

Files by machine learning module
ModuleFiles
Vision34,176
CoreML19,520
FoundationModels12,320

Rarest

The five rarest are TipKit, FoundationModels, CloudKit, ActivityKit and CoreML.

TipKit is the rarest module, in 4,368 files.

Foundation is in 1,330 times as many files as TipKit.

The five rarest modules
ModuleFiles
TipKit4,368
FoundationModels12,320
CloudKit15,104
ActivityKit16,256
CoreML19,520

Top ten

Foundation, SwiftUI and UIKit are the three most imported, each in more than 2.8 million files.

Foundation, SwiftUI and UIKit lead the ten.

The ten most imported modules
RankModuleFiles
1Foundation5,808,128
2SwiftUI3,190,784
3UIKit2,879,488
4AppKit530,432
5Combine338,944
6SwiftData244,736
7AVFoundation189,184
8CoreData172,032
9Observation100,864
10WebKit76,416

Groups

UI and data modules are level, at 6.8 and 6.7 million.

Import hits by group
GroupModulesFiles
Apple UI96,803,920
Apple data and state76,747,264
Apple frameworks8399,680

What is in the file

A number for each framework

SwiftUI against UIKit, SwiftData against Core Data, and 20 more.

Every row in one file

24 modules, each with its group and its count of files.

No code and no names

The file holds counts only, with no repository and no developer.

How the files were counted

One search per module, counts only.

Write one search per module

Each search is the word import followed by the module name, restricted to Swift.

Ask the code search

One request per module, at least seven seconds apart.

Ask again on a partial answer

When the service marked a search incomplete, it was run again up to three times.

Keep the count

Only the count went into the CSV, with the module and its group.

What a package has to import

A package that draws a feedback board has to meet apps where they are, and the counts say that is both UIKit and SwiftUI. UIKit is in 2,879,488 files and SwiftUI in 3,190,784, so neither can be skipped. Foundation sits in 5,808,128 files, which makes it the safe base for networking and storage, and AppKit, in 530,432 files, is the smaller but real audience on the Mac.

Every import beyond those costs reach. WebKit is in 76,416 files and UserNotifications in 67,456, so a board shown in a web view or a push prompt for a shipped request fits a minority of the code counted here. A package that asks only for Foundation and one of the two interface frameworks works in the widest set of projects.

What these numbers leave out

  • These are files, not apps or developers.
  • A large count is rounded by the search, so two modules within about 10 percent of each other are level.
  • There is no date filter, so a count holds every year since the module existed.
  • A vendored copy or a tutorial template counts again in each file.
  • The search leaves out most forks, and an import in a comment or a string counts too.
  • A module imported under a name that was not searched is missing, and no code was read.

What people ask about Swift imports

Is SwiftUI imported more than UIKit?

Yes, in 3,190,784 files against 2,879,488, a ratio of 1.1 to 1.

Is SwiftData more common than Core Data?

Yes, in 244,736 files against 172,032, a ratio of 1.4 to 1.

How many files import Foundation?

5,808,128, the most of the 24 modules in the file.

Which Apple framework is imported most after the UI ones?

AVFoundation, in 189,184 files, then MapKit in 74,368.

How many files import FoundationModels?

12,320 files, as read on 1 November 2026.

Does the file include code?

No. It holds the module, the group and the number of files.

May a site quote these figures?

Yes. Credit this page and the read date, 1 November 2026, and take any module row from the CSV.

Collect feature requests in an iOS app

Your first board is free, with one project and 100 votes. The 14 day trial of Lite or Pro needs no card.