Hi everyone! 
I’m working on a mobile app in Thunkable where I want to let users either take a photo or upload an image of an ingredient list from a food product. My goal is to extract the text from the image using OCR and then automatically check if the ingredients contain gluten (e.g., words like wheat, barley, malt, etc.).
I’m currently using the OCR.Space API to get the text, and then I want to compare it against a list of gluten-containing keywords.
Is there anyone who has built something similar or who can help me make sure the logic works correctly in Thunkable?
Any help or example blocks would be really appreciated! 
Thank you!
1 Like
What you have looks good but this will cause problems:

One thing that is helpful to know about Thunkable is that every block is evaluated in order. So that set of blocks will first get the value of app variable Ingrediente
(for example “Sugar”) and then set a variable with that value’s name to the label’s text (for example app variable Sugar
). But that variable doesn’t exist in your project.
Avoid using the set app variable " "
block. Instead, use the set app variable Ingrediente
block at the top of the Variables drawer.
My app is currently not working properly, and I’m not sure why.
Maybe I’m missing some settings or configuration steps — or I just don’t know what’s wrong.
That’s why I’m looking for a working example or some guidance to help me figure it out.
Thanks a lot in advance! 
I have yet to see a truly successful OCR app using Thunkable. The reason for that – and I’ve done a fair amount of testing to know this – is that the key factor is the API itself. If you pay for a good OCR service, your app will work great. If you don’t, it simply won’t work… at least not consistently.
I’m not sure where OCR.Space falls into that range but if you aren’t paying for it then it’s probably not worth the trouble to see if you can get this to work.
Once you have a decent OCR API in place, you should be getting one of the following:
- A correct detection (e.g. “STOP” on a stop sign image returns “STOP”)
- An incorrect detection (e.g. “STOP” on a stop sign image returns “8I0B” or something similarly useless)
- An error
I’m curious where you’re at with that…?
If you want to share a link to your project, I can take a look at what you have but I don’t have a working example to show you.