Finding the JLCPCB component parts library frustrating to navigate, [Jan Mrázek] took matters into his own hands and made an open-source parametric search utility. We’ve all probably wasted time before trying to track down a particular flavor of a part, and this tool promises to make the process easier. It downloads data from the JLCPCB parts site upon initialization and presents the user with typical selection filters for categories and parameter values. You can install it yourself on GitHub Pages, or [Jan] provides a link to his site.
For the curious, the details of how to pull parts information from the JLBPCB site can be found in the project’s source code. We like it when a distributor provides this level of access to their part details and parameters, allowing others to sort and filter the parts in ways not originally envisioned by the site design team. We think this is a win-win situation — distributors can’t sell parts that designers can’t find.
If [Jan]’s name sounds familiar, it should be. We have written about several of his projects before, two of them are also PCB designer tools ( KiCad Board Renderings and KiCad Panelization ).
28 thoughts on “Improved Part Searches For JLCPCB Parts”
Access to cheap PCA services like JLCPCB is a game-changer, so projects like this are very welcome.
Sure, OSHPark can do me a board and stencils for a board with a QFP-100 part. But it’s a pain to assemble, and LCSC is often cheaper than Digikey, so…yeah…
This is super cool! JLCPCB’s integration with EasyEDA is already pretty handy. I’m seeing this as a tool to use before the design phase when I’m just considering what parts might get smashed together on a board.
Will give this a try as I use JLPCB and LCSC a lot due to the tight integration to EasyEDA, reliable service and some nice niche parts they carry.
A shame JLPCB and LCSC are only doing courier deliveries at the moment so you need to add US$22 minimum to any order and also you used to be able to combine shipping on JLPCB and LCSC but no longer the case so I find myself going back to RS or digikey for small orders as they have free delivery in most cases and that courier money saved buys a lot of stuff.
I was able to combine my last JLCPCB and LCSC order a couple of months ago.
unfortunately this is no longer possible:
“We regret to inform you that due to the export declaration issues, the combined shipment for LCSC components orders and JLCPCB orders has been canceled since Mar. 11th GMT+8 2019. Currently, PCB orders and component orders are shipped separately.”
Thank ou. JLCPCB is my current favorite, but their component selection is a bit painful. Getting from Kicad to JLCPCB was a bit trying so I wrote a simple conversion aplication to ease the paths from Kicad’s pos file to JLC’s cpl and bom files.
A text based conversion file converts from popular Kicad footprint names to JLC footprint names. Additionally a rotational offset can be introduced to correct for rotational variations.
correction for the top and bottom location formats is also provided.
Get your version here.
You might be interested in KiKit and the “fab” command: https://github.com/yaqwsx/KiKit/blob/master/doc/fabrication/jlcpcb.md
It exports Gerber’s, bom and pos files in a single command. It also supports parts placement corrections to match KiCad footprints to JLC footprints.
Excellent! I will use this. I particularly like the basic/extended sort capability. Now, could you do it for LCSC’s catalog? :-)
JLCPCB is using a subset of LCSC parts. My catalog works by fetching list of available components from JLCPCB and then fetching component properties from LCSC, where at least some parameters are in semi-machine-readable form. JLCPCB offers nothing but a text description. So in theory, it is possible – right now it is just a catalog of a subset of LCSC components. However, in practice it would be much more complicated to build LCSC catalog. LCSC has no public API, so all data have to be scraped and they don’t allow you to make more than 100 requests per minute. That’s why my JLCPCB catalog uses incremental updates, since it took me 3,5 days just to download the initial database from LCSC. And currently, I have no idea how to obtain all LCSC order codes/product pages from their page.
That’s why I added the smiley! Much larger problem…
It doesn’t work for me, I entered ESP8266EX and got back a forever-spinning doughnut. I am not seeing any blocked scripts. I know the ESP8266EX is on the JLPCB site, I searched for it successfully there. I’m using the latest mainstream Firefox browser on a laptop.
Hi, the project was tested on all major browsers. Could you provide me with the precise Firefox version, your operating system and exact steps to reproduce the issue? Otherwise, I won’t be able to fix it. Ideally open an issue on https://github.com/yaqwsx/jlcparts
I have a secondary Firefox Profile with “never remember history” setting. I think that disallowes indexDB usage – even temporarily. So it doesn’t work on that profile. (Works well with my regular Profile).
Then I am afraid I can’t do anything about it. Since I didn’t want to complicate my life with having a backend which scales well, I decided to make the project without a backed – it is just a static site rebuilt every night by Travis. Therefore, IndexedDB is must have for using the project.
But you are right – my code does not check if the browser supports IndexedDB. I should add such check.
Is there an advantage over using the API versus downloading the CSV? Currently I just download the CSV and filter in Libreoffice which works 3x as well als using the JLCPCB website. But this is soooooooo much better.
Not sure which CSV you are referring. If it is the Excel table on the JLCPCB website (https://jlcpcb.com/componentSearch/uploadComponentInfo), it does not contain part attributes thus you cannot do parametric search. I glue attributes from LCSC (this is where I use their internal API) to the table from LCSC.
I mean I glue attributes from LCSC to the table from JLC.
Oh right, I mean that table. Maybe it was a CSV before and I didn’t notice they switched to xls.
So you use the API from LCSC? Didn’t you say they don’t have any? Or just no public API?
They have no public API. This was all reverse engineered. Given a LCSC number of a component I know how to get its attributes (but there is a limit of 100 requests/minute, so it is really slow). However, I have no efficient way to query all LCSC codes on LCSC. That is why my tool does not work with LCSC.
This should maybe dump all LCSC components in a day: https://pastebin.com/6UxH4gXX
https://lcsc.com/api/products/search returns 30 results and has a rate limit of 30 per minute. As far as I can see, the results include all the parametric data. So you can dump an entire category quite quick. At 500k components, that should get you the entire database in half a day. You have to supply the entire request headers. You can dump entire Main categories. Have a look here (untested): https://pastebin.com/4WKFWZa1
Thanks! This might be a solid foundation. However, to make it work out-of-the-box in my setup, daily update should be completed within 40 minutes (Travis timeout). And I guess there’s no easy way to detect newly added components or fetch new stock.
There is https://lcsc.com/products/New-Arrivals_11033.html but I kinda doubt it is complete. I kinda remember seeing a getStock API somewhere, but I can’t find it anymore. If you are interested and can do something good with it, I might crawl the stock maybe once a week and push to github (or whatever).
40 Minutes means you only need like 20 Proxy servers. Maybe you can get away with using different ipv6 addresses. Then it is trivial to circumvent the rate limiting… I’m not sure if they’d like that though.
If you just want the JLCPCB stock, the xls will be the easiest option.
Although https://jlcpcb.com/shoppingCart/smtGood/selectSmtComponentList returns up to 50 results and doesn’t look rate limited…
Let me know if I can help in any way (maybe we should find somewhere else to talk)
Mathias: Thanks for the insight. JLC PCB stock is working (well, the whole post above is about it). There were just a few people in the comments who were interested in my solution over all components from LCSC. I am not sure if it is necessary, since LCSC already has UI for parametric search.
Anyway. If you have interest in all the LCSC parts, I uploaded a dump here: https://github.com/LCSC-Dumper/LCSC-Parts. There are ~500k parts in there, but maybe there are 70k dupes, at least the internal ID matches (not the LCSC part number).
I put the script on Github and also the first 200k parts. https://github.com/LCSC-Dumper/LCSC-Dumper
This is incredible! And well timed (for me) because I just started my first project where we’ll be ordering from JLCPCB. Your blessed tool makes life pleasant again.
This parametric search is awesome, to bad JLCPCB doesn’t buy from you to add to their website! During these difficult time with suppy issues an great addition would to select a part and get a notification when the part is back in stock?
Please be kind and respectful to help make the comments section excellent. (Comment Policy)