Swift Blog
swift.org · Company blog · on HN since 2015
The official blog of the Swift programming language project, covering releases, open-source work, platform support and language interoperability.
What HN saysHN links it for Swift's official site and docs, such as C++ interop. Commenters call Swift a good environment and debate the site's homepage design.
307HN people shared it
203linked it in comments
253stories submitted
13Kstory points
2 months agolast shared
2015people per year2026
Most-shared posts
- 1Swift 3.0 Preview 1 Snapshots27 people · 5 points · first shared 2015 · discussion on HN
- 2Mixing Swift and C++17 people · 5 points · first shared 2023 · discussion on HN
- 3Swift is Open Source15 people · 2.0K points · first shared 2015 · 432 comments on HN
- 4Swift 5.3 will bring official Windows support11 people · 22 points · first shared 2020 · 1 comments on HN
- 5About11 people · first shared 2016
- 6Swift Server Work Group10 people · 4 points · first shared 2018 · discussion on HN
- 7The Future of Foundation10 people · 3 points · first shared 2022 · discussion on HN
- 8Writing Gnome Apps with Swift8 people · 571 points · first shared 2024 · 282 comments on HN
- 9Swift Homomorphic Encryption7 people · 322 points · first shared 2024 · 122 comments on HN
- 10Swift Package Manager7 people · 4 points · first shared 2015 · discussion on HN
- 11The Swift Linux Port7 people · 3 points · first shared 2015 · discussion on HN
- 12Linux7 people · first shared 2024
- 13Swift on Windows6 people · 325 points · first shared 2020 · 203 comments on HN
- 14Swift UTF-8 String6 people · 124 points · first shared 2019 · 95 comments on HN
- 15Swift API Design Guidelines6 people · 79 points · first shared 2016 · 3 comments on HN
What HN people wrote when they linked it
spikepuppet · 2024-03-31
Happy too! So my main resource is Hacking With Swift (https://www.hackingwithswift.com), specifically the 100 days of SwiftUI Course. It takes you over Swift and SwiftUI. I've paired this with the official Swift site (https://www.swift.org) so I can dig into the language more, and Apple Documentation where appropriate to get used to using the tools.
In terms of finding it, it was a bit of a shot in the dark. I did some poking around and this popped up the most, specifically because I was looking for iOS specific materials. I'm sure if you want to make cross platform apps there's probably a whole host of great resources!
b3morales · 2021-12-20
That's probably the view of Apple execs, but it is not the rhetoric that comes out of the Swift Org itself:
https://www.swift.org/
> a programming language to empower everyone to turn their ideas into apps on any platform.
https://www.swift.org/about/
> the best available language for uses ranging from systems programming, to mobile and desktop apps, scaling up to cloud services
> a web-based REPL can when working with Linux server-side code
> it is now free to be ported across a wide range of platforms, devices, and use cases. Our goal is to provide source compatibility for Swift across all platforms ... extend the cross-platform capabilities of Swift ... source compatibility for Swift code across all platforms ...
> Open-source Swift can be used on Linux to build Swift libraries and applications
> We’d love your help to bring Swift to even more computing platforms.
vesak · 2018-05-05
Swift is a brilliant environment. Always good to see more adoption for it.
http://swift.org
I simplify it as an easier Rust that comes with an official REPL.
Someone · 2025-12-21
On my iPad, without scrolling, the screen shows almost nothing, just a download button and some text that, I think users will ignore. I think that’s a waste of valuable screen estate.
Also, apart from a quote from David Heinemeier Hansson the home page doesn’t even mention that ruby is a programming language.
For comparison, the following all mention that above the fold, with a short phrase indicating what you would want to use the language.
- https://www.python.org/ has “Python is a programming language that lets you work quickly and integrate systems more effectively. Learn More”
- https://www.perl.org/ has “Perl is a highly capable, feature-rich programming language with over 37 years of development”
- https://www.php.net/ has “A popular general-purpose scripting language that is especially suited to web development. Fast, flexible and pragmatic, PHP powers everything from your blog to the most popular websites in the world.”
- https://www.swift.org/ has “Swift is the powerful, flexible, multiplatform programming language. Fast. Expressive. Safe.”
lukeh · 2026-02-19
Swift actually has excellent C++ interop [1] (compared to other languages, but, I guess, not good enough for Ladybird).
[1] https://www.swift.org/documentation/cxx-interop/
bnchrch · 2026-02-02
Swift has all the things I want in a language
- Strong Typing
- Great Performance
- Actor Model Concurrency [0]
- Modern Ergonomics
- Corporate Backing
- Performance
- Functional Style
- LLMs perform well with it [1]
- Usable across iOS, Android, Web, and Browsers [2][3]
The only thing its missing is adoption outside of the iOS space.
I'm not sure it will be able to make that leap, but the ingredients are there.
If it does I'd be happy to make it my primary language.
----------------
[0] https://www.hackingwithswift.com/quick-start/concurrency/what-is-an-ac…
[1] https://github.com/Tencent-Hunyuan/AutoCodeBenchmark/blob/main/figures…
[2] https://www.swift.org/blog/nightly-swift-sdk-for-android/
[3] https://vapor.codes/
ChrisMarshallNY · 2025-05-08
I’ve been using Apple’s docc[0]. It mostly just means that I write my code docs the same way as I always have (Doxygen markdown style), but it has an additional “compile” step, that produces a build artifact that integrates into the Xcode Documentation engine. You can make a pretty rich experience, with things like images and videos, all linked directly to your code.
Fairly cool, but it requires Xcode, to work properly. It doesn’t really have a decent “export” capability, for things like GitHub Pages. There’s a fairly awkward way prescribed by Apple, that is annoying AF, and breaks easily, so I don’t usually bother. I’ll use Jazzy Docs to produce the GH Pages output.
I would love it, if GitHub would parse docc artifacts for GH Pages, but it’s probably too much of a pain to do.
[0] https://www.swift.org/documentation/docc/
st3fan · 2025-02-01
Go has been shipping for more than a decade as a .tgz and does not have this stigma at all ...
Anyway, you probably missed the following
https://www.swift.org/install/linux/
I see packages for all major distros there.
But people will probably mention some distro not listed and say the mainstream distro support is a farce. For some reason people have set the bar for Swift incredibly unrealistically high and there will always be something wrong it.
Your loss though. Swift is amazing. Both on MacOS and Linux.
ghayes · 2024-06-10
Try building a Swift project without Xcode. It works great. `swift build` and `swift test` all work significantly better than with Xcode, and there's no `xcodeproj` file. I am building in ST4 with good LSP and no problems at all.
https://www.swift.org/getting-started/library-swiftpm/
† The doc is about building a library, but building an executable works the same.
nielsbot · 2023-09-07
Apple also has memory-safer languages it is moving to:
Swift: A memory-safer systems programming language: https://www.swift.org
Firebloom: A memory-safer C variant: https://support.apple.com/en-il/guide/security/sec30d8d9ec1/web
Not sure what the answer is for existing memory-unsafe code.
pjmlp · 2023-04-09
Ah the excuses when facts are put on the table.
"Fast. Swift is intended as a replacement for C-based languages (C, C++, and Objective-C). "
-- https://www.swift.org/about/
"From its earliest conception, Swift was built to be fast. Using the incredibly high-performance LLVM compiler technology, Swift code is transformed into optimized machine code that gets the most out of modern hardware. The syntax and standard library have also been tuned to make the most obvious way to write your code also perform the best whether it runs in the watch on your wrist or across a cluster of servers.
Swift is a successor to both the C and Objective-C"
-- https://developer.apple.com/swift/#fast
Jtsummers · 2023-01-30
> OK. It's a language by Apple, so it's not surprising that it's on Apple's website, even though I think if you want people to get the idea that it's a serious independent project you probably should give it its own top-level site personally.
You mean like it does have? https://www.swift.org/
easeout · 2022-07-03
For what it's worth, Apple offers Numbers free on the App Store. I'm not sure how deep the financial functions go.
Graphing: The classic has been ported by its original author. Not free but a pleasant surprise https://swift.org/blog/graphing-calculator/
thewebcount · 2022-03-03
If you haven't already, please crawl <https://developer.apple.com> and <https://swift.org>.
syspec · 2021-12-06
> The goal of the Swift project is to create the best available language for uses ranging from systems programming, to mobile and desktop apps, scaling up to cloud services.
> Fast. Swift is intended as a replacement for C-based languages (C, C++, and Objective-C). As such, Swift must be comparable to those languages in performance for most tasks. Performance must also be predictable and consistent, not just fast in short bursts that require clean-up later. There are lots of languages with novel features — being fast is rare.
Those are literally the stated goals. It does not get more clear than saying "Swift is intended to be a replacement for C-based languages (C, C++)..."
[0]https://www.swift.org/about/
skohan · 2020-07-16
It's worth noting that wider support (including official Windows support) is a stated goal of the next language version:
https://swift.org/blog/5-3-release-process/
gh123man · 2020-06-02
Slightly off topic, but as a swift developer (https://swift.org/) the usage of swift/T in this project really confused me. Is swift/T in any way related to Apple's swift language?
The naming conflict makes googling the differences fairly challenging.
Eric_WVGG · 2020-05-30
> The goal of the Swift project is to create the best available language for uses ranging from systems programming, to mobile and desktop apps, scaling up to cloud services.
https://swift.org/about/
> "My goal for Swift has always been, and still is, total world domination," Chris Lattner, the creator of Swift, said onstage at Apple's Worldwide Developers Conference in 2017.
https://www.businessinsider.com/developers-love-swift-apple-programmin…
I'm having trouble finding the specific bit about "default language for computer science," might have been his interview on the ATP podcast. anyway
NobodyNada · 2020-02-14
- Bugs. There’s so many weird bugs in SwiftUI, and the framework is so opaque and poorly-documented that it takes hours of trial and error to find an ugly workaround.
That being said, hopefully these issues will get better with time. Swift 5.2 includes a new diagnostics architecture [0] that is supposed to greatly improve SwiftUI error messages. The 10-subviews limitation will be removed once we have variadic generics; a Swift Evolution proposal is currently being drafted [1] and is expected to land in Swift 6.
[0]: https://swift.org/blog/new-diagnostic-arch-overview/
[1]: https://github.com/technicated/swift-evolution/blob/variadic-generics/…
stephencanon · 2019-02-10
FWIW, you can install Xcode 10.1 on High Sierra, and use the Swift.org 5.0 toolchain (https://swift.org/download/#snapshots) or build swift from source. You can't ship App Store apps this way, but it works great for experiments.
colonelrascals · 2018-08-14
Swift is #6 on that list, TypeScript is #4.
This was meant to highlight that Swift developers don't seem unhappy with the language
Swift is evolving slowly, but JavaScript is making very quick progress through TC39 during the same time span that Swift was alive.
I'm not sure this is a bad thing
Swift has ambiguous and biased leadership but JavaScript has a well defined and established committee with members from major competitors who have common interest in the language succeeding.
I think this is a bit biased. Have you read Swift's Community Guidelines? https://swift.org/community/#communication
I don't really have a dog in this fight and would love some input from a Swift developer.
I still claim that introducing JavaScript is not the solution.
veidr · 2018-06-04
I am sad this HN topic isn't trending up more, because THAT would change EVERYTHING.
(By which I mean everything whiny MS-skeptics have said today (myself included).)
It would be a knockout PR move, suddenly sucking all the wind out of the sails of all knee-jerk-antiMicrosoftism surrounding this acquisition.
Satya, bro, you should really take a page out of Apple's playbook, and announce right now that you are going to.
(That way, whether you really do[1], or you don't[2], most people won't remember the idea anyway...)
[1]: https://swift.org
[2]: https://en.wikipedia.org/wiki/FaceTime
jrs95 · 2018-05-11
Apple actually sort of does have a backend framework: WebObjects. They just seem to have deprecated it in favor of other solutions. Still, I've noticed at least iTunes Connect is still using it. And for what it's worth, Swift is going to have more server related stuff coming to the standard library (https://swift.org/server-apis/), and I wouldn't be surprised if Apple starts adopting this eventually as well as it continues to improve.
morbidhawk · 2016-04-05
objc.io and nshipster were my two favorite iOS dev blogs. It's a bummer there haven't been new posts for a while. They still have years worth of really high quality content though
Edit: Another blog worth following is the Swift Blog (https://swift.org/blog/) and the old Swift Blog (https://developer.apple.com/swift/blog/) by Apple/Swift engineers
merb · 2016-01-21
> You have to relearn how a function looks like in the first place. Return types are at the end, parameter types are after the parameter name separated by a colon.
baroque syntax?
Like these:
- https://swift.org/getting-started
- https://doc.rust-lang.org/book/functions.html
- https://golang.org/doc/effective_go.html#functions
- https://kotlinlang.org/docs/reference/functions.html
Sorry but you pretty much say clojure is the best, however it has a lisp syntax, which IS baroque and most people aren't use to this.
These days if you want to have a functional style.
You eiter use Scala or Kotlin.
Clojure is too much of a unicorn. People won't learn this. Also people doesn't care how good the language is or what design patterns were used. People use these languages cause they think the language has a actual value for them (as you think about clojure)
renownedmedia · 2015-12-03
http://downforeveryoneorjustme.com/swift.org
It's not just you! http://swift.org looks down from here.
rickstanley · 2026-01-31
Toady I used GLM 4.7 to port a C++ project of mine to Rust, so I could read and toy with it, to get into the language: https://codeberg.org/RickStanley/agatetepe-rs.
Really interesting results, not sure how well it is written but works. I was quite found of Rust syntax; it certainly is not as convoluted as C++ (in my opinion).
Then I read this article. Since I was already eye-balling Swift for some time, I decided to give it a try and port to it, using Rust implementation as reference, and this time, without much of A. I. assistance, if I could help it.
I'm using an qcow2 Debian trixie arm image in UTM as playground. I found out that there is no packaging for Debian at the time of this writing: https://github.com/swiftlang/swift/issues/60690. No problem! They have a script for installing: https://www.swift.org/install/linux/
curl -O https://download.swift.org/swiftly/linux/swiftly-$(uname -m).tar.gz && \
tar zxf swiftly-$(uname -m).tar.gz && \
./swiftly init --quiet-shell-followup && \
. "${SWIFTLY_HOME_DIR:-$HOME/.local/share/swiftly}/env.sh" && \
hash -r
But, god damn, the size is huge,
Unsupported Linux platform
Debian GNU/Linux 13 (trixie) is not an officially supported platform, but the toolchains for another platform may still work on it.
Please select the platform to use for toolchain downloads:
0) Cancel
1) Ubuntu 24.04
2) Ubuntu 22.04
3) Ubuntu 20.04
4) Ubuntu 18.04
5) Fedora Linux 39
6) RHEL 9
…
frizlab · 2025-04-27
> Let's say i want to expose an async call to a local sqlite instance on android.
I don’t know, I don’t do android dev. I just made sure my library was running on it then moved on. I know Swift is working on having bidirectional interoperability with Java[1], so I guess when they do it’ll just work? But I did not dig more on the subject.
Regarding the size I’m not sure as I never compiled a binary that is actually useful. I make sure everything runs, but as I’m building a library this goes to building the tests then running them on WASI and that’s it.
Regarding the Swift toolchain version, using swiftly[2] is recommended nowadays if you don’t need Xcode. Using the default toolchain provided by Xcode usually brings trouble when using SDKs. Using swiftly you’ll get the same experience as on Linux basically. (This will probably change, but it is like so currently.)
[1] https://github.com/swiftlang/swift-java
[2] https://www.swift.org/install/macos/#:~:text=Swiftly
manmal · 2024-06-12
Great writeup, and I love that the authors looked at a lot of other languages. The solution section on how to prevent races is a bit light still - I‘m curious how they will solve this.
I think there will need to be exceptions to a strict race-free model eto not take away from dart‘s current capabilities, and without forcing people into something like a borrow checker. Swift has `@unchecked Sendable` which lets you tell the compiler "I promise I'll take care myself to keep everything in there race-free".
What I‘ve been missing in Swift are tools that let me add safety _within_ such @unchecked Sendables. There's the Swift Atomics lib: https://www.swift.org/blog/swift-atomics/, but its quite limited in its capabilities. So for now, I find myself reaching for tools provided by the community, like pointfree's LockIsolated: https://github.com/pointfreeco/swift-concurrency-extras/blob/main/Sour…
neonsunset · 2024-04-08
How would C track references for heap-allocated data originating from (A)RC-based language?
I don't think what you say on .NET correlates with reality - you are not supposed to pass managed objects across FFI (you just can't, it won't let you unless you do unsafe cast shenanigans) - the correct way is to either marshal the data or use blittable representation (plain structs can be passed as is, either by reference or value, same goes for arrays/pointers of primitives). On the rare occasion where unmanaged code needs to keep a GC object alive, it is passed via special GCHandle but that's an exception not the rule.
Swift has its own high level representation for such objects which are very much not FFI compatible. ARC in Swift is a feature that requires compiler involvement to work correctly, and its structs are not FFI compatible unless they are "trivial". Swift also has its own more advanced Swift Library Evolution ABI, which is strictly not C ABI you expect out of your regular library and has its own calling convention and semantics.
Overall, there seem to be strange misconceptions about how these languages work so it would be best to check with the documentation first:
.NET P/Invoke (FFI):
- https://learn.microsoft.com/en-us/dotnet/standard/native-interop/pinvo…
- https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/int…
Swift non-C ABI:
- https://github.com/apple/swift/blob/main/docs/LibraryEvolution.rst
-…