How can build a keyboard from scratch with swift

how can build my custom keyboard with swiftui please how can I connect the keyboard extension to aswiftuiview

So you want to make a custom keyboard that can be used like in place of the default keyboard?

Or create a custom keyboard that will be shown on a custom view in your app?

yes I want to build a custom keyboard extension with swiftui that can be used anywhere once added via settings I see a lot of tutorials on it with uikit but I want to do it with swiftui is my final assessment to get a job I just need the steps on how to do it

I haven’t done this before with the keyboard, so I’m not 100% sure, but you can put any SwiftUI view into a UIKit view, so you could probably still follow most tutorials

that’s the problem I can’t do that, tried like this is my last opportunity in getting this job if I can see how to represent letter A on keyboard extension with swiftui I can start from there.and it can be done because after complaining on countless of trials they actually showed me the source code with swiftui… so its possible its just the integration I did one with just swiftuiviews but they said it must be a custom keyboard extension that can be used in safari

Can you post the instructions you have? I don’t think I understand

I built that with story board from scratch its working but not fast on real device so they I said should build on swiftui like that from scratch


so after several months 0f training with codewithchris and some research I can build basically any ui view on swiftui but the problem is taking this keyboard to display on the keyboard extension with all buttons functions working like I did with the storyboard and not just views like keyboard extension that can you use on your safari browser and not just input text field

Hey there!

I found an article from Apple’s documentation:
https://developer.apple.com/documentation/uikit/keyboards_and_input/creating_a_custom_keyboard

However, based on the docs, I think the Custom Keyboard Extension from the Application Extension group template is still in UIKit.

However, that should give you all of the project files you need including the config that would tell iOS that what you have is a custom keyboard extension app.

sadly I’m a beginner don’t understand how to implement those documentations on swiftui that’s in uikit I guess…I was shown the source code of swiftui so I know is very possible but not given when I complained is no where to be found that’s why I brought up here