android parse web page - jsoup. use in intelliJ IDE

android parse web page – jsoup. use in intelliJ IDE

now you can parse web page like jQUery, “jsoup”.

install jsoup,

Download jsoup jar, and import to your project. save jsoup.jar in libs folder in your project.

open intelliJ.

  • project, right click -> module
  • add, select “jar or directories”
  • import from libs folder jars.


Before start coding, edit AndroidManifest.xml, enable internet permission. insert line before Application tag.

<uses-permission android:name="android.permission.INTERNET" /><br></br>


when we want to access web page by URL, have to use thread to process this task, so i use AsyncTask for query web page.

class testAsynch extends AsyncTask
protected String doInBackground(Void...arg0) {
Log.d("DoINBackGround","On doInBackground...");

try {
Document doc = Jsoup.connect("").get();
Log.d("info", doc.title());
} catch (IOException e) {
return "You are at PostExecute";

execute in your,

new testAsynch().execute();


Web developer, focus on website fullstack, special JavaScript, and love sharing developing experience and communicate with developers.